sakibomber
asked on
EOF - easy question
IS EOF a keyword? I have an INI file that has text in it. At the end of the file is an EOF. The code uses the While Not EOF. Heres what the file looks like now:
text here
text here
text here
EOF
I need to change this file to this:
text here
text here
text here
EOC
More Text
More Text
EOF
So in the code....can I just say...While Not EOC? Or is EOF a keyword???? Otherwise I think I could just parse the string.
Thanks,
saki
text here
text here
text here
EOF
I need to change this file to this:
text here
text here
text here
EOC
More Text
More Text
EOF
So in the code....can I just say...While Not EOC? Or is EOF a keyword???? Otherwise I think I could just parse the string.
Thanks,
saki
EOF when read from the INI file is NOT a keyword, but a String. "EOF"
EOF in code IS a Keyword: EOF(1)
So if your looking for this line when looping through the file you would just put: (If your using Line Input)
Line Input #1,strLine
if strline = "EOF" then
'Do something
else
'Do something else
end if
EOF in code IS a Keyword: EOF(1)
So if your looking for this line when looping through the file you would just put: (If your using Line Input)
Line Input #1,strLine
if strline = "EOF" then
'Do something
else
'Do something else
end if
eof stands for "End of File"
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
thanks :)
line input #1,abc
it means that the abc variable will store the value of line and then you have to check the loop as
while not abc = "EOF"
or whatever you want
kashif