Restored from previous forum. Originally posted by Danilo.
>Using OpenFile here works quite fine for me (on this computer)
>and together with Usefile, PB doesn't mistake which is output
>and which is input.
Yes it should work, but it didnt work
for Ralf.
So i looked at this little piece
of code and it didnt work for me too.
(I think Openfile() worked before for me)
I changed the checks (IF OpenFile...)
and inserted 2 Console commands
(OpenConsole() at the beginning and
PrintN(TEMP.s) after ReadString())
After a ReadString(), the printed
String was empty. Hmm...
So i only changed the OpenFile()
in ReadFile() and the String
was read correctly this time.
1st Problem found. Corrected.
>And I always use WOF at the top with while and wend.
I found out that the program
cant find the EOF() if you use
it with While...Wend.
The program didnt stop (i can see the
CPUtime at every time on a performance
monitor on the right side of my desktop).
Hmm... weird stuff.
I let it run for a few seconds...
BANG!... it crashed my Win2000
so badly. Wow. Its hard to crash
Win2000 so hard.
So i changed the thing to use
Repeat and it worked.
Repeat checks after the last
String is read, so it works
fine.
>Each system is different:):)
Yes, but with Windows every system
should be the same. Its not.
You see this by using the Win-API.
It works on Win2000, doesnt work
on Win95 and makes strange colors
on WinXP....
Anyway, i like the WinAPI -
but its soooo big that its
sometimes not easy to find
what you need.
I use MSDN, search for a function
and it gives me 200 hits...
cya,
...Danilo
(registered PureBasic user)