Post

 Resources 

Console


A solution... Rag on a Stick (0 replies, 0 views) (2000-Oct-20)
-
What I did was for reading it back, I used Input mode rather than binary mode. This could cause problems if you have a combination of strings and integers and stuff. How I did it: Dim MyString As String 'Our string 'Initialise it MyString = "Hello" 'Open a file - Binary mode Open "c:\test.txt" For Binary As #1 'Put our string in it Put #1, 1, MyString 'Close the file Close #1 'Clear the string (just to prove 'it is actually working) MyString = "" 'Open the file - Input mode Open "c:\test.txt" For Input As #1 'Get the string Input #1, MyString 'Output the string MsgBox MyString 'Close the file Close #1 'Delete the file Kill "c:\test.txt"


-
Up One Level | Back to Forum


Copyright © 2002 - 2004 Eric Coleman, Peter Kuchnio , et. al.
There have been 80 visitors within the last 20 minutes
RSS News Feed