Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / DBC - Batch Writing to File

Author
Message
Ginga
18
Years of Service
User Offline
Joined: 3rd Jul 2006
Location: Dorset, England
Posted: 13th Aug 2006 23:13
Ok, heres my problem -:

Its for a code based program, rather than a standalone.

I have an Array "COORD(X,Y,1)", (this is set incode by 2 variables "height" + "width"), and i want to save all the info in the array to a file.. say "test.txt"

as its a variable i cant really write out each line seperatly cos there would be hundreds. From my Experiance in Visual Studio, i know you can use For/Next statements to do this, but it doesn't seem to work on DBC.

I use the code:



in VB, that would work, any help would b mucho appreciated
Alien 001
19
Years of Service
User Offline
Joined: 4th Jul 2005
Location: Gateshead UK
Posted: 14th Aug 2006 14:15
I see the problem it is with the X and Y they need an value. X = 10 , Y = 10. place these befor the for next loop as an example.
Ginga
18
Years of Service
User Offline
Joined: 3rd Jul 2006
Location: Dorset, England
Posted: 14th Aug 2006 16:02
Alien 001 .. Cheers for the imput, i should of mention that the variables r set before the For/next loop started.

I have figured out what was wrong, and that it was saying that the file already existed, i THOUGHT it meant on the second loop, but it actually meant at the start of the loop, as it thought i held the 'save' button down again. I've added a 'wait 50' command and its holding atm, tho i'm gunna have to put an 'If file exists' in there.

Login to post a reply

Server time is: 2024-11-26 13:34:18
Your offset time is: 2024-11-26 13:34:18