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.

DarkBASIC Professional Discussion / Problem Saving My Arrays (Trust Me.. To answer this you got to be good)

Author
Message
The Lone Programmer
23
Years of Service
User Offline
Joined: 29th Jan 2003
Location: California, USA
Posted: 9th Nov 2003 06:08
Hi...
As some of you know, most stuff hates me.
Well, I know how to save arrays and I know how to load arrays. That is ok for me.

Here is my problem.
I dont use normal arrays any more.. They are with types now. I can not save them now.. Why is that? I have tried:
save array "Test.txt",array(9)
save array "Test.txt",array(9).name$

my type is
type name
name$
endtype
dim array(9) as name

This is AN EXAMPLE. My code is not as dumb as this one.
So how do i save an array if its a type.. I just get an error.

Please tell me it can be done, and please tell me the answer.

Thanks,
Nicolas

*Current Project: Untitled RPG
*Working With: Vash the Stampede 815
http://www.blazing-fire.tk
Codger
23
Years of Service
User Offline
Joined: 23rd Nov 2002
Location:
Posted: 9th Nov 2003 07:19
Make a loop and write each element of the array using the appropriate write string ; write integer etc statement

read by reversing the process

System
PIII 650 MZ H.P. Pavillion
394 Mem GeForce 4 400MX
ReD_eYe
23
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 9th Nov 2003 15:07
what codger said, i don't think you can save an array properly after declaring them as a UDT so just write it all into a text file instead.


Go on, click on my signature image, you know you want to
Favourite smiley>>>

Login to post a reply

Server time is: 2026-07-26 17:35:54
Your offset time is: 2026-07-26 17:35:54