Is this the right syntax to save Form data into an ini file:
Code:Open App.Path & "\Settings.ini" For Output As #1
Print #1, Form14.Controls
Close #1
Printable View
Is this the right syntax to save Form data into an ini file:
Code:Open App.Path & "\Settings.ini" For Output As #1
Print #1, Form14.Controls
Close #1
did you try it?
i am sure it would give an error
try like
if you have controls with no default property this will give an error, but will work correctly for textboxes, labels and some othersvb Code:
for each c in form14.controls print #1, c.name & " = " & c next
for list an combo boxes you may need to loop through all the items, if you want to reload them later
for dynamically created controls or control arrays you may need to save the position and size and index number
really depend on what you are wanting to do with all the controls
Lol, I just forgot to say. That way would save all of the conrol's data on the Form. Including the Command Buttons and everything else like that. So I am going to Print all of the information that I want to keep and not anything that I don't want to keep. It also is very much quicker than searching for all of the data. Instead I found out that just Printing the Form data, that I want to keep is quicker in deed!!
Thanks for your help!!