|
-
Nov 22nd, 2002, 08:03 PM
#1
Thread Starter
New Member
Opening a file with "FreeFile" ** RESOLVED **
If I open a file in "FreeFile" which takes the next available file number, and then later want to read or write to the file, what tells me the number that was assigned to that file.
I haven't actually done this yet, but to write to a file "Write #1" needs the number, am I right?
Does freefile give the programmer a number or is there a variable that holds the number somewhere?
(pardon the simplicity of my questons, I'm REALLY new to this)
thanks
billyvb
Last edited by billyvb; Nov 22nd, 2002 at 08:20 PM.
Do not regret growing older...
It is a privilege denied to many.
-
Nov 22nd, 2002, 08:05 PM
#2
Stuck in the 80s
Like this:
VB Code:
Dim f As Integer
f = FreeFile
Open "C:\file.txt" For Ouput As #f
Write #f, "Text"
Close #f
-
Nov 22nd, 2002, 08:19 PM
#3
Thread Starter
New Member
Thanks Hobo
I can't believe I didn't think of that!! Sometimes I scare myself...
billyvb
Do not regret growing older...
It is a privilege denied to many.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|