Announcement
Collapse
No announcement yet.
Save xButton Properties in ini file
Collapse
X
-
Originally posted by claus707 View PostI think that in the second script you should have something like this:
Code:SetXbuttonenabled = INIFile.GetValue("AutoPlay\\Docs\\ButtonState3.ini", "ButtonState3", "SetXbuttonenabled"); xButton.SetProperties("xButton3", {Enabled=SetXbuttonenabled});
Leave a comment:
-
I think that in the second script you should have something like this:
Code:SetXbuttonenabled = INIFile.GetValue("AutoPlay\\Docs\\ButtonState3.ini", "ButtonState3", "SetXbuttonenabled"); xButton.SetProperties("xButton3", {Enabled=SetXbuttonenabled});
Leave a comment:
-
Save xButton Properties in ini file
Hello.
i want to Save xButton Properties in '".ini file" and then load but after Saved and Load Script in "on Preload" have Error :
Argument 2 must be of type table.
Script for Save in xbutton Properties :
Code:ButtonState3 = xButton.GetProperties("xButton3"); if xButton.GetProperties("xButton3").Enabled then INIFile.SetValue("AutoPlay\\Docs\\ButtonState3.ini", "ButtonState3", "SetXbuttonenabled", "true"); else INIFile.SetValue("AutoPlay\\Docs\\ButtonState3.ini", "ButtonState3", "SetXbuttonenabled", "false"); end
Code:SetXbuttonenabled = INIFile.GetValue("AutoPlay\\Docs\\ButtonState3.ini", "ButtonState3", "SetXbuttonenabled"); xButton.SetProperties("xButton3", SetXbuttonenabled);
can anybody tell me what wrong ?Tags: None
Leave a comment: