keen Posted December 18, 2006 Share Posted December 18, 2006 Hey Guys. I need to know how to do a few things: 1: I need to know how to make something write a ini file but make the key cout off (Example: 1... 2... 3...) 2: I need to know how to make a space in the file when it writes it. Like go down two lines then put the submitted data. 3: I need to know how to make iniread to read the different keys from question one. Thanks in avance -keen [center]Kesne's Bar & Grill[/center] Link to comment Share on other sites More sharing options...
mikehunt114 Posted December 18, 2006 Share Posted December 18, 2006 Question #1: For $i = 1 To 10 IniWrite("Test.ini", "Section One", $i, "value number " & $i) NextoÝ÷ ٲبf®¶sdæw&FRgV÷CµFW7BæægV÷C²ÂgV÷Cµ6V7FöâöæRgV÷C²ÂgV÷C²gV÷C²Â5$ÄboÝ÷ ٲبv®¶sdf÷"b33c¶ÒFò æ&VBgV÷CµFW7BæægV÷C²ÂgV÷Cµ6V7FöâöæRgV÷C²Âb33c¶ÂgV÷C´FFæ÷Bf÷VæBâgV÷C²¤æW@ IE Dev ToolbarMSDN: InternetExplorer ObjectMSDN: HTML/DHTML Reference Guide[quote]It is surprising what a man can do when he has to, and how little most men will do when they don't have to. - Walter Linn[/quote]--------------------[font="Franklin Gothic Medium"]Post a reproducer with less than 100 lines of code.[/font] Link to comment Share on other sites More sharing options...
FuryCell Posted December 18, 2006 Share Posted December 18, 2006 (edited) For $i = 1 To 10 IniRead("Test.ini", "Section One", $i, "Data not found.") Next Edited December 18, 2006 by SolidSnake HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code. Link to comment Share on other sites More sharing options...
mikehunt114 Posted December 18, 2006 Share Posted December 18, 2006 Whoops, that was a pretty useless IniRead. IE Dev ToolbarMSDN: InternetExplorer ObjectMSDN: HTML/DHTML Reference Guide[quote]It is surprising what a man can do when he has to, and how little most men will do when they don't have to. - Walter Linn[/quote]--------------------[font="Franklin Gothic Medium"]Post a reproducer with less than 100 lines of code.[/font] Link to comment Share on other sites More sharing options...
keen Posted December 20, 2006 Author Share Posted December 20, 2006 Its not counting off. It goes right to 10001. Any help? expandcollapse popup#include <GUIConstants.au3> #include <File.au3> #include <XSkin.au3> ; folder of skin $Skin_Folder = @ScriptDir & "\graphics files" $XSkinGui = XSkinGUICreate("Vault - Version 1.0.0", 1120, 790, $Skin_Folder) $Icon_Folder = @ScriptDir & "\icons" $XIcon = XSkinIcon($XSkinGui, 3) ;$XIcon[1] = Exit,$XIcon[2] = minimize,$XIcon[3] = Help WinMove($XSkinGui, "", 149, 114); move the gui GUISetBkColor(0xFFFFFF) $Pic1 = GUICtrlCreatePic("S:\My Documents\JORDANS STUFF\Vault - Mrs. Johnsons Program\Graphics Files\Main-Image.gif", 104, 0, 750, 150, BitOR($SS_NOTIFY,$WS_GROUP)) $Button1 = GUICtrlCreateButton("Admin Login", 900, 100, 81, 25, 0) GUICtrlCreateTab(75, 170, 975, 547) $Date1 = GUICtrlCreateDate("", 97, 680, 233, 24) $TabSheet2 = GUICtrlCreateTabItem("Check Out") $Label1 = GUICtrlCreateLabel("Welcome to the checkout system. Please fill out the information at the bottom of the screen to check a book out.", 14, 237, 966, 20, $SS_CENTER) $Group1 = GUICtrlCreateGroup("Check Out", 129, 320, 857, 337) $Input1 = GUICtrlCreateInput("", 314, 368, 241, 24) $Label2 = GUICtrlCreateLabel("Your Name (First And Last):", 145, 368, 163, 20) $Label3 = GUICtrlCreateLabel("Class Period:", 145, 416, 84, 20) $Input2 = GUICtrlCreateInput("", 233, 416, 17, 24) $Label4 = GUICtrlCreateLabel("Name Of Book:", 297, 416, 95, 20) $Input3 = GUICtrlCreateInput("", 401, 416, 241, 24) $Label5 = GUICtrlCreateLabel("Date Checked Out:", 689, 416, 116, 20) $Input4 = GUICtrlCreateInput("", 809, 416, 145, 24) $Button2 = GUICtrlCreateButton("Log Book Checkout", 489, 576, 130, 25, 0) GUICtrlCreateGroup("", -99, -99, 1, 1) $TabSheet3 = GUICtrlCreateTabItem("Returning Books") $Label1 = GUICtrlCreateLabel("Welcome to the checkout system. Please fill out the information at the bottom of the screen to Return a book.", 14, 237, 966, 20, $SS_CENTER) $Group2 = GUICtrlCreateGroup("Return", 129, 320, 857, 337) $Inpur1 = GUICtrlCreateInput("", 314, 368, 241, 24) $Labelr2 = GUICtrlCreateLabel("Your Name (First And Last)", 145, 368, 163, 20) $Labelr4 = GUICtrlCreateLabel("Name Of Book:", 297, 416, 95, 20) $Inpur3 = GUICtrlCreateInput("", 401, 416, 241, 24) $Labelr5 = GUICtrlCreateLabel("Date Returned:", 689, 416, 116, 20) $Inpur4 = GUICtrlCreateInput("", 809, 416, 145, 24) $Laber3 = GUICtrlCreateLabel("Class Period:", 145, 416, 84, 20) $Inpur2 = GUICtrlCreateInput("", 233, 416, 17, 24) $Buttor2 = GUICtrlCreateButton("Log Book Return", 489, 576, 110, 25, 0) For $i = 1 To 10000 Next GUISetState(@SW_SHOW) While 1 $msg = GUIGetMsg() Switch $msg Case $Button2 IniWrite (@ScriptDir & "\CheckedOut.ini","",$i," Name: "&GUICTrlRead($Input1)&" Period: "&GUICTrlRead($Input2)&" Name of book: "&GUICTrlRead($Input3)&" Date Checked Out: "&GUICTrlRead($Input4)) GUICtrlSetData ($Input1,"") GUICtrlSetData ($Input2,"") GUICtrlSetData ($Input3,"") GUICtrlSetData ($Input4, "") MsgBox (0,"Logged", "Checkout Information has been Logged!") Case $Buttor2 IniWrite (@ScriptDir & "\Return.ini","",$i,@CRLF &" Name: "&GUICTrlRead($Inpur1)&" Name of book: "&GUICTrlRead($Inpur3)&" Period: "&GUICTrlRead($Inpur2)&" Date Returned: "&GUICTrlRead($Inpur4)) GUICtrlSetData ($Inpur1,"") GUICtrlSetData ($Inpur3,"") GUICtrlSetData ($Inpur2,"") GUICtrlSetData ($Inpur4,"") MsgBox (0,"Logged", "Return Information has been Logged!") Case $XIcon[1] GUIDelete() Case $XIcon[2] GUISetState(@SW_MINIMIZE) EndSwitch WEnd [center]Kesne's Bar & Grill[/center] Link to comment Share on other sites More sharing options...
Valuater Posted December 20, 2006 Share Posted December 20, 2006 For $i = 1 To 10000 Next is the same as $i = 10000 except it has a loop that is doing nothing 8) Link to comment Share on other sites More sharing options...
keen Posted December 20, 2006 Author Share Posted December 20, 2006 How can i fix it? [center]Kesne's Bar & Grill[/center] Link to comment Share on other sites More sharing options...
Valuater Posted December 20, 2006 Share Posted December 20, 2006 1While 1 $msg = GUIGetMsg() Switch $msg Case $Button2 IniWrite (@ScriptDir & "\CheckedOut.ini","",$i," Name: "&GUICTrlRead($Input1)&" Period: "&GUICTrlRead($Input2)&" Name of book: "&GUICTrlRead($Input3)&" Date Checked Out: "&GUICTrlRead($Input4)) GUICtrlSetData ($Input1,"") GUICtrlSetData ($Input2,"") GUICtrlSetData ($Input3,"") GUICtrlSetData ($Input4, "") MsgBox (0,"Logged", "Checkout Information has been Logged!") Case $Buttor2they should not be the same name2$i = 0; or $i = ( read how many lies are in the file )While 1 $msg = GUIGetMsg() Switch $msg Case $Button2$i += 1 IniWrite (@ScriptDir & "\CheckedOut.ini","",$i," Name: "&GUICTrlRead($Input1)&" Period: "&GUICTrlRead($Input2)&" Name of book: "&GUICTrlRead($Input3)&" Date Checked Out: "&GUICTrlRead($Input4)) GUICtrlSetData ($Input1,"") GUICtrlSetData ($Input2,"") GUICtrlSetData ($Input3,"") GUICtrlSetData ($Input4, "") MsgBox (0,"Logged", "Checkout Information has been Logged!") Case $Buttor2***** change name$i += 1 IniWrite (@ScriptDir & "\Return.ini","",$i,@CRLF &" Name: "&GUICTrlRead($Inpur1)&" Name of book: "&GUICTrlRead($Inpur3)&" Period: "&GUICTrlRead($Inpur2)&" Date Returned: "&GUICTrlRead($Inpur4)) GUICtrlSetData ($Just ideas8) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now