writing text files

View: New views
2 Messages — Rating Filter:   Alert me  

writing text files

by Jude DaShiell :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Script started on Sun Jul 26 05:00:36 2009
jude@localhost:~$ vbnc test.vb
Visual Basic.Net Compiler version 0.0.0.5914 (Mono 2.4 - r)
Copyright (C) 2004-2008 Rolf Bjarne Kvinge. All rights reserved.


/home/jude/test.vb (4,27) : Error VBNC99997: You've encountered something in the compiler which is not implemented. Please file a bug (see instructions here: http://mono-project.com/Bugs)
There were 1 errors and 0 warnings.
Compilation took 00:00:02.1372740
jude@localhost:~$ cat test.vb
Imports System.IO
Module Module1
Sub Main()
Dim TextFile As New Stream.Writer("test.txt")
TextFile.WriteLine("Line 1")
TextFile.WriteLine("www.java2s.com")
TextFile.Close()
Console.WriteLine("text file created test.txt")
End Sub
End Module
jude@localhost:~$ exit
exit

Script done on Sun Jul 26 05:01:36 2009

I had intended to create a csv data file for a project and use it for
recordkeeping but apparently this first method isn't implemented in vbnc.
Fortunately, java2s.com offers another method so I'll take a look at that
next.

_______________________________________________
Mono-vb mailing list
Mono-vb@...
http://lists.ximian.com/mailman/listinfo/mono-vb

Re: writing text files

by Rolf Bjarne Kvinge-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

> Dim TextFile As New Stream.Writer("test.txt")

You have an extra dot here, it should read StreamWriter not Stream.Writer.

Rolf


_______________________________________________
Mono-vb mailing list
Mono-vb@...
http://lists.ximian.com/mailman/listinfo/mono-vb