ashley Posted July 31, 2007 Share Posted July 31, 2007 (edited) ok i made this so you can have too GUI's maybe with Too different person things can be hidden in it... Would work best with ini file... but i don't know who do that... so maybe some can add a function button on each one to save what ever they type and then text time comes up as a label... well here it is... expandcollapse popup#cs ---------------------------------------------------------------------------- AutoIt Version: 3.2.2.0 Author: Multi outcome GUI --- with password protection --- Warning: Don't edit more than i said(unless it will make it better) It MAY stop working.... TODO: 1) Add input box to store info... 2) Add Save button to save input info to INI file 3) Add INI file... 4) And much more Please help me make this better!!! #ce ---------------------------------------------------------------------------- #include <GUIConstants.au3> #include <array.au3> #include <String.au3> ;edit these $hint = "Password hint here" Dim $Password[3] = ["yea", "yea1", "yea2"] Dim $Name[3] = ["Ashley", "Joshua", "Fabian"] ;Edit these -end #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Password Dialog", 251, 93, 310, 249) GUISetIcon("D:08.ico") $MaskEdit1 = GUICtrlCreateInput("", 8, 32, 233, 21, BitOR($ES_PASSWORD, $ES_AUTOHSCROLL, $WS_BORDER, $WS_CLIPSIBLINGS), BitOR($WS_EX_CLIENTEDGE, $WS_EX_STATICEDGE)) GUICtrlSetTip(-1, $hint) $Button1 = GUICtrlCreateButton("&OK", 86, 64, 75, 25, 0) $Button2 = GUICtrlCreateButton("&Cancel", 167, 64, 75, 25, 0) $Label1 = GUICtrlCreateLabel("Enter password to use file", 8, 12, 125, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 ConsoleWrite(_ArraySearch($Password, GUICtrlRead($MaskEdit1)) & @CRLF) If _ArraySearch($Password, GUICtrlRead($MaskEdit1)) = -1 Then MsgBox(1024, "Not acepted", "The password enter is not acepted") Exit EndIf For $i = 0 To UBound($Password) - 1 If GUICtrlRead($MaskEdit1) == $Password[$i] Then MsgBox(1024, "Acepted", "The password enter is acepted") GUIDelete() Call("_User" & $i) EndIf Next Case $Button2 Exit EndSwitch WEnd Func _User0() MsgBox(1024, "Hello", "Welcome " & $Name[0] & "! :)") ;edit this (the first GUI) #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[0] & "'s Text", 634, 448, 194, 116) $Edit1 = GUICtrlCreateEdit("", 16, 16, 601, 393) GUICtrlSetData(-1, "Enter here your Text...") $MenuItem1 = GUICtrlCreateMenu("File") $MenuItem2 = GUICtrlCreateMenuItem("Save", $MenuItem1) $MenuItem3 = GUICtrlCreateMenuItem("Load", $MenuItem1) $MenuItem4 = GUICtrlCreateMenuItem("", $MenuItem1) $MenuItem5 = GUICtrlCreateMenuItem("Exit", $MenuItem1) $MenuItem6 = GUICtrlCreateMenu("Info...") $MenuItem7 = GUICtrlCreateMenuItem("User Info", $MenuItem6) $MenuItem8 = GUICtrlCreateMenuItem("App Info", $MenuItem6) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the first GUI)- end While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $MenuItem2 $Text = GUICtrlRead($Edit1) $Text = _StringEncrypt(1, $Text, $Password[0]) FileDelete($Name[0] & ".txt") FileWrite($Name[0] & ".txt", $Text) MsgBox(64, "Information", "Finished saving") Case $MenuItem3 If FileExists($Name[0] & ".txt") Then $MsgBox = MsgBox(68, "Information", "If you load the text, you will lost your text that's currently in the textbox. Are you sure you want to load?") If $MsgBox = 6 Then $Text = FileRead($Name[0] & ".txt") $Text = _StringEncrypt(0, $Text, $Password[0]) GUICtrlSetData($Edit1, $Text) EndIf Else MsgBox("64", "Information", "Nothing to load, save at fierst!;)") EndIf Case $MenuItem5 Exit Case $MenuItem7 MsgBox("64", "Information", "Logged in as: " & $Name[0] & " | Password: " & $Password[0]) Case $MenuItem8 MsgBox("64", "Information", "Original by 'ashley', edited by 'GtaSpider' and 'Fabian'") EndSwitch WEnd EndFunc ;==>_User0 Func _User1() MsgBox(1024, "Hello", "Welcome " & $Name[1]& "! :)") ;Second Gui here #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[1] & "'s Text", 634, 448, 194, 116) $Edit1 = GUICtrlCreateEdit("", 16, 16, 601, 393) GUICtrlSetData(-1, "Enter here your Text...") $MenuItem1 = GUICtrlCreateMenu("File") $MenuItem2 = GUICtrlCreateMenuItem("Save", $MenuItem1) $MenuItem3 = GUICtrlCreateMenuItem("Load", $MenuItem1) $MenuItem4 = GUICtrlCreateMenuItem("", $MenuItem1) $MenuItem5 = GUICtrlCreateMenuItem("Exit", $MenuItem1) $MenuItem6 = GUICtrlCreateMenu("Info...") $MenuItem7 = GUICtrlCreateMenuItem("User Info", $MenuItem6) $MenuItem8 = GUICtrlCreateMenuItem("App Info", $MenuItem6) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the Second GUI)- end While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $MenuItem2 $Text = GUICtrlRead($Edit1) $Text = _StringEncrypt(1, $Text, $Password[1]) FileDelete($Name[1] & ".txt") FileWrite($Name[1] & ".txt", $Text) MsgBox(64, "Information", "Finished saving") Case $MenuItem3 If FileExists($Name[1] & ".txt") Then $MsgBox = MsgBox(68, "Information", "If you load the text, you will lost your text that's currently in the textbox. Are you sure you want to load?") If $MsgBox = 6 Then $Text = FileRead($Name[1] & ".txt") $Text = _StringEncrypt(0, $Text, $Password[1]) GUICtrlSetData($Edit1, $Text) EndIf Else MsgBox("64", "Information", "Nothing to load, save at fierst!;)") EndIf Case $MenuItem5 Exit Case $MenuItem7 MsgBox("64", "Information", "Logged in as: " & $Name[1] & " | Password: " & $Password[1]) Case $MenuItem8 MsgBox("64", "Information", "Original by 'ashley', edited by 'GtaSpider' and 'Fabian'") EndSwitch WEnd EndFunc ;==>_User1 Func _User2() MsgBox(1024, "Hello", "Welcome " & $Name[2] & "! :)") ;Second Gui here #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[2] & "'s Text", 634, 448, 194, 116) $Edit1 = GUICtrlCreateEdit("", 16, 16, 601, 393) GUICtrlSetData(-1, "Enter here your Text...") $MenuItem1 = GUICtrlCreateMenu("File") $MenuItem2 = GUICtrlCreateMenuItem("Save", $MenuItem1) $MenuItem3 = GUICtrlCreateMenuItem("Load", $MenuItem1) $MenuItem4 = GUICtrlCreateMenuItem("", $MenuItem1) $MenuItem5 = GUICtrlCreateMenuItem("Exit", $MenuItem1) $MenuItem6 = GUICtrlCreateMenu("Info...") $MenuItem7 = GUICtrlCreateMenuItem("User Info", $MenuItem6) $MenuItem8 = GUICtrlCreateMenuItem("App Info", $MenuItem6) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the Third GUI)- end While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $MenuItem2 $Text = GUICtrlRead($Edit1) $Text = _StringEncrypt(1, $Text, $Password[2]) FileDelete($Name[2] & ".txt") FileWrite($Name[2] & ".txt", $Text) MsgBox(64, "Information", "Finished saving") Case $MenuItem3 If FileExists($Name[2] & ".txt") Then $MsgBox = MsgBox(68, "Information", "If you load the text, you will lost your text that's currently in the textbox. Are you sure you want to load?") If $MsgBox = 6 Then $Text = FileRead($Name[2] & ".txt") $Text = _StringEncrypt(0, $Text, $Password[2]) GUICtrlSetData($Edit1, $Text) EndIf Else MsgBox("64", "Information", "Nothing to load, save at fierst!;)") EndIf Case $MenuItem5 Exit Case $MenuItem7 MsgBox("64", "Information", "Logged in as: " & $Name[2] & " | Password: " & $Password[2]) Case $MenuItem8 MsgBox("64", "Information", "Original by 'ashley', edited by 'GtaSpider' and 'Fabian'") EndSwitch WEnd EndFunc ;==>_User2 any comments welcome... Please help me to update this to make it better thanks Fabian and GtaSpider Edited September 3, 2007 by ashley Free icons for your programs Link to comment Share on other sites More sharing options...
Toady Posted July 31, 2007 Share Posted July 31, 2007 Pretty cool, good job! Be sure to run spell check before you post too, I had a hard time understand what you where saying. www.itoady.com A* (A-star) Searching Algorithm - A.I. Artificial Intelligence bot path finding Link to comment Share on other sites More sharing options...
ashley Posted July 31, 2007 Author Share Posted July 31, 2007 Pretty cool, good job! Be sure to run spell check before you post too, I had a hard time understand what you where saying.i dont have it... sorry... Free icons for your programs Link to comment Share on other sites More sharing options...
Toady Posted July 31, 2007 Share Posted July 31, 2007 http://www.spellcheck.net/ www.itoady.com A* (A-star) Searching Algorithm - A.I. Artificial Intelligence bot path finding Link to comment Share on other sites More sharing options...
ashley Posted July 31, 2007 Author Share Posted July 31, 2007 70 views and 3 replys that makes me sad!!! Free icons for your programs Link to comment Share on other sites More sharing options...
GtaSpider Posted July 31, 2007 Share Posted July 31, 2007 (edited) Hi Ashley! Nice script But arrays maybe here are better then strings.. look @this: expandcollapse popup#cs ---------------------------------------------------------------------------- AutoIt Version: 3.2.2.0 Author: Multi outcome GUI --- with password protection --- Warning: Don't edit more than i said(unless it will make it better) It MAY stop working.... TODO: 1) Add input box to store info... 2) Add Save button to save input info to INI file 3) Add INI file... 4) And much more Please help me make this better!!! #ce ---------------------------------------------------------------------------- #include <GUIConstants.au3> #include <array.au3> ;edit these $hint = "Password hint here" Dim $Password[2] = ["yea", "yea1"] Dim $Name[2] = ["Ashley", "Joshua"] ;Edit these -end #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Password Dialog", 251, 93, 310, 249) GUISetIcon("D:08.ico") $MaskEdit1 = GUICtrlCreateInput("", 8, 32, 233, 21, BitOR($ES_PASSWORD, $ES_AUTOHSCROLL, $WS_BORDER, $WS_CLIPSIBLINGS), BitOR($WS_EX_CLIENTEDGE, $WS_EX_STATICEDGE)) GUICtrlSetTip(-1, $hint) $Button1 = GUICtrlCreateButton("&OK", 86, 64, 75, 25, 0) $Button2 = GUICtrlCreateButton("&Cancel", 167, 64, 75, 25, 0) $Label1 = GUICtrlCreateLabel("Enter password to use file", 8, 12, 125, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 ConsoleWrite(_ArraySearch($Password, GUICtrlRead($MaskEdit1)) & @CRLF) If _ArraySearch($Password, GUICtrlRead($MaskEdit1)) = -1 Then MsgBox(1024, "Not acepted", "The password enter is not acepted") Exit EndIf For $i = 0 To UBound($Password) - 1 If GUICtrlRead($MaskEdit1) == $Password[$i] Then MsgBox(1024, "Acepted", "The password enter is acepted") GUIDelete() Call("_User" & $i) EndIf Next Case $Button2 Exit EndSwitch WEnd Func _User0() MsgBox(1024, "Hello", "Welcome " & $Name[0]) ;edit this (the first GUI) #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[0] & "'s Gui", 633, 447, 193, 115) $Label1 = GUICtrlCreateLabel("This is " & $Name[0] & "'s GUI the password for this GUI is " & $Password[0], 88, 136, 500, 24) GUICtrlSetFont(-1, 12, 400, 0, "MS Sans Serif") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the first GUI)- end EndFunc ;==>_User0 Func _User1() MsgBox(1024, "Hello", "Welcome " & $Name[1]) ;Second Gui here #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[1] & "'s Gui", 633, 447, 193, 115) $Label1 = GUICtrlCreateLabel("This is " & $Name[1] & "'s GUI the password for this GUI is " & $Password[1], 88, 136, 500, 24) GUICtrlSetFont(-1, 12, 400, 0, "MS Sans Serif") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the Second GUI)- end EndFunc ;==>_User1 Mfg Spider Edited July 31, 2007 by GtaSpider www.AutoIt.de - Moderator of the German AutoIt Forum  Link to comment Share on other sites More sharing options...
James Posted August 1, 2007 Share Posted August 1, 2007 Hey thats pretty neat Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
ashley Posted August 1, 2007 Author Share Posted August 1, 2007 Hi Ashley! Nice script But arrays maybe here are better then strings.. look @this: expandcollapse popup#cs ---------------------------------------------------------------------------- AutoIt Version: 3.2.2.0 Author: Multi outcome GUI --- with password protection --- Warning: Don't edit more than i said(unless it will make it better) It MAY stop working.... TODO: 1) Add input box to store info... 2) Add Save button to save input info to INI file 3) Add INI file... 4) And much more Please help me make this better!!! #ce ---------------------------------------------------------------------------- #include <GUIConstants.au3> #include <array.au3> ;edit these $hint = "Password hint here" Dim $Password[2] = ["yea", "yea1"] Dim $Name[2] = ["Ashley", "Joshua"] ;Edit these -end #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Password Dialog", 251, 93, 310, 249) GUISetIcon("D:08.ico") $MaskEdit1 = GUICtrlCreateInput("", 8, 32, 233, 21, BitOR($ES_PASSWORD, $ES_AUTOHSCROLL, $WS_BORDER, $WS_CLIPSIBLINGS), BitOR($WS_EX_CLIENTEDGE, $WS_EX_STATICEDGE)) GUICtrlSetTip(-1, $hint) $Button1 = GUICtrlCreateButton("&OK", 86, 64, 75, 25, 0) $Button2 = GUICtrlCreateButton("&Cancel", 167, 64, 75, 25, 0) $Label1 = GUICtrlCreateLabel("Enter password to use file", 8, 12, 125, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 ConsoleWrite(_ArraySearch($Password, GUICtrlRead($MaskEdit1)) & @CRLF) If _ArraySearch($Password, GUICtrlRead($MaskEdit1)) = -1 Then MsgBox(1024, "Not acepted", "The password enter is not acepted") Exit EndIf For $i = 0 To UBound($Password) - 1 If GUICtrlRead($MaskEdit1) == $Password[$i] Then MsgBox(1024, "Acepted", "The password enter is acepted") GUIDelete() Call("_User" & $i) EndIf Next Case $Button2 Exit EndSwitch WEnd Func _User0() MsgBox(1024, "Hello", "Welcome " & $Name[0]) ;edit this (the first GUI) #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[0] & "'s Gui", 633, 447, 193, 115) $Label1 = GUICtrlCreateLabel("This is " & $Name[0] & "'s GUI the password for this GUI is " & $Password[0], 88, 136, 500, 24) GUICtrlSetFont(-1, 12, 400, 0, "MS Sans Serif") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the first GUI)- end EndFunc ;==>_User0 Func _User1() MsgBox(1024, "Hello", "Welcome " & $Name[1]) ;Second Gui here #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[1] & "'s Gui", 633, 447, 193, 115) $Label1 = GUICtrlCreateLabel("This is " & $Name[1] & "'s GUI the password for this GUI is " & $Password[1], 88, 136, 500, 24) GUICtrlSetFont(-1, 12, 400, 0, "MS Sans Serif") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the Second GUI)- end EndFunc ;==>_User1 Mfg Spider Dude thanks for the updated script... ill post this on first post... thanks.. do u know how to make it like a personal secreat keeper or somet so i will know what was typed in... bit like a diary... Free icons for your programs Link to comment Share on other sites More sharing options...
ashley Posted August 1, 2007 Author Share Posted August 1, 2007 Hey thats pretty neat thanks..can you think of any ways to update it... Free icons for your programs Link to comment Share on other sites More sharing options...
Fabian Posted September 3, 2007 Share Posted September 3, 2007 (edited) I've edited a bit, take a look: expandcollapse popup#cs ---------------------------------------------------------------------------- AutoIt Version: 3.2.2.0 Author: Multi outcome GUI --- with password protection --- Warning: Don't edit more than i said(unless it will make it better) It MAY stop working.... TODO: 1) Add input box to store info... 2) Add Save button to save input info to INI file 3) Add INI file... 4) And much more Please help me make this better!!! #ce ---------------------------------------------------------------------------- #include <GUIConstants.au3> #include <array.au3> #include <String.au3> ;edit these $hint = "Password hint here" Dim $Password[3] = ["yea", "yea1", "yea2"] Dim $Name[3] = ["Ashley", "Joshua", "Fabian"] ;Edit these -end #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Password Dialog", 251, 93, 310, 249) GUISetIcon("D:08.ico") $MaskEdit1 = GUICtrlCreateInput("", 8, 32, 233, 21, BitOR($ES_PASSWORD, $ES_AUTOHSCROLL, $WS_BORDER, $WS_CLIPSIBLINGS), BitOR($WS_EX_CLIENTEDGE, $WS_EX_STATICEDGE)) GUICtrlSetTip(-1, $hint) $Button1 = GUICtrlCreateButton("&OK", 86, 64, 75, 25, 0) $Button2 = GUICtrlCreateButton("&Cancel", 167, 64, 75, 25, 0) $Label1 = GUICtrlCreateLabel("Enter password to use file", 8, 12, 125, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 ConsoleWrite(_ArraySearch($Password, GUICtrlRead($MaskEdit1)) & @CRLF) If _ArraySearch($Password, GUICtrlRead($MaskEdit1)) = -1 Then MsgBox(1024, "Not acepted", "The password enter is not acepted") Exit EndIf For $i = 0 To UBound($Password) - 1 If GUICtrlRead($MaskEdit1) == $Password[$i] Then MsgBox(1024, "Acepted", "The password enter is acepted") GUIDelete() Call("_User" & $i) EndIf Next Case $Button2 Exit EndSwitch WEnd Func _User0() MsgBox(1024, "Hello", "Welcome " & $Name[0] & "! :)") ;edit this (the first GUI) #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[0] & "'s Text", 634, 448, 194, 116) $Edit1 = GUICtrlCreateEdit("", 16, 16, 601, 393) GUICtrlSetData(-1, "Enter here your Text...") $MenuItem1 = GUICtrlCreateMenu("File") $MenuItem2 = GUICtrlCreateMenuItem("Save", $MenuItem1) $MenuItem3 = GUICtrlCreateMenuItem("Load", $MenuItem1) $MenuItem4 = GUICtrlCreateMenuItem("", $MenuItem1) $MenuItem5 = GUICtrlCreateMenuItem("Exit", $MenuItem1) $MenuItem6 = GUICtrlCreateMenu("Info...") $MenuItem7 = GUICtrlCreateMenuItem("User Info", $MenuItem6) $MenuItem8 = GUICtrlCreateMenuItem("App Info", $MenuItem6) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the first GUI)- end While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $MenuItem2 $Text = GUICtrlRead($Edit1) $Text = _StringEncrypt(1, $Text, $Password[0]) FileDelete($Name[0] & ".txt") FileWrite($Name[0] & ".txt", $Text) MsgBox(64, "Information", "Finished saving") Case $MenuItem3 If FileExists($Name[0] & ".txt") Then $MsgBox = MsgBox(68, "Information", "If you load the text, you will lost your text that's currently in the textbox. Are you sure you want to load?") If $MsgBox = 6 Then $Text = FileRead($Name[0] & ".txt") $Text = _StringEncrypt(0, $Text, $Password[0]) GUICtrlSetData($Edit1, $Text) EndIf Else MsgBox("64", "Information", "Nothing to load, save at fierst!;)") EndIf Case $MenuItem5 Exit Case $MenuItem7 MsgBox("64", "Information", "Logged in as: " & $Name[0] & " | Password: " & $Password[0]) Case $MenuItem8 MsgBox("64", "Information", "Original by 'ashley', edited by 'GtaSpider' and 'Fabian'") EndSwitch WEnd EndFunc ;==>_User0 Func _User1() MsgBox(1024, "Hello", "Welcome " & $Name[1]& "! :)") ;Second Gui here #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[1] & "'s Text", 634, 448, 194, 116) $Edit1 = GUICtrlCreateEdit("", 16, 16, 601, 393) GUICtrlSetData(-1, "Enter here your Text...") $MenuItem1 = GUICtrlCreateMenu("File") $MenuItem2 = GUICtrlCreateMenuItem("Save", $MenuItem1) $MenuItem3 = GUICtrlCreateMenuItem("Load", $MenuItem1) $MenuItem4 = GUICtrlCreateMenuItem("", $MenuItem1) $MenuItem5 = GUICtrlCreateMenuItem("Exit", $MenuItem1) $MenuItem6 = GUICtrlCreateMenu("Info...") $MenuItem7 = GUICtrlCreateMenuItem("User Info", $MenuItem6) $MenuItem8 = GUICtrlCreateMenuItem("App Info", $MenuItem6) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the Second GUI)- end While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $MenuItem2 $Text = GUICtrlRead($Edit1) $Text = _StringEncrypt(1, $Text, $Password[1]) FileDelete($Name[1] & ".txt") FileWrite($Name[1] & ".txt", $Text) MsgBox(64, "Information", "Finished saving") Case $MenuItem3 If FileExists($Name[1] & ".txt") Then $MsgBox = MsgBox(68, "Information", "If you load the text, you will lost your text that's currently in the textbox. Are you sure you want to load?") If $MsgBox = 6 Then $Text = FileRead($Name[1] & ".txt") $Text = _StringEncrypt(0, $Text, $Password[1]) GUICtrlSetData($Edit1, $Text) EndIf Else MsgBox("64", "Information", "Nothing to load, save at fierst!;)") EndIf Case $MenuItem5 Exit Case $MenuItem7 MsgBox("64", "Information", "Logged in as: " & $Name[1] & " | Password: " & $Password[1]) Case $MenuItem8 MsgBox("64", "Information", "Original by 'ashley', edited by 'GtaSpider' and 'Fabian'") EndSwitch WEnd EndFunc ;==>_User1 Func _User2() MsgBox(1024, "Hello", "Welcome " & $Name[2] & "! :)") ;Second Gui here #Region ### START Koda GUI section ### Form= $Form1 = GUICreate($Name[2] & "'s Text", 634, 448, 194, 116) $Edit1 = GUICtrlCreateEdit("", 16, 16, 601, 393) GUICtrlSetData(-1, "Enter here your Text...") $MenuItem1 = GUICtrlCreateMenu("File") $MenuItem2 = GUICtrlCreateMenuItem("Save", $MenuItem1) $MenuItem3 = GUICtrlCreateMenuItem("Load", $MenuItem1) $MenuItem4 = GUICtrlCreateMenuItem("", $MenuItem1) $MenuItem5 = GUICtrlCreateMenuItem("Exit", $MenuItem1) $MenuItem6 = GUICtrlCreateMenu("Info...") $MenuItem7 = GUICtrlCreateMenuItem("User Info", $MenuItem6) $MenuItem8 = GUICtrlCreateMenuItem("App Info", $MenuItem6) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### ;edit this (the Third GUI)- end While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $MenuItem2 $Text = GUICtrlRead($Edit1) $Text = _StringEncrypt(1, $Text, $Password[2]) FileDelete($Name[2] & ".txt") FileWrite($Name[2] & ".txt", $Text) MsgBox(64, "Information", "Finished saving") Case $MenuItem3 If FileExists($Name[2] & ".txt") Then $MsgBox = MsgBox(68, "Information", "If you load the text, you will lost your text that's currently in the textbox. Are you sure you want to load?") If $MsgBox = 6 Then $Text = FileRead($Name[2] & ".txt") $Text = _StringEncrypt(0, $Text, $Password[2]) GUICtrlSetData($Edit1, $Text) EndIf Else MsgBox("64", "Information", "Nothing to load, save at fierst!;)") EndIf Case $MenuItem5 Exit Case $MenuItem7 MsgBox("64", "Information", "Logged in as: " & $Name[2] & " | Password: " & $Password[2]) Case $MenuItem8 MsgBox("64", "Information", "Original by 'ashley', edited by 'GtaSpider' and 'Fabian'") EndSwitch WEnd EndFunc ;==>_User2 -it can save the entered text -encrypt it with the user's pass -and load it Edited September 5, 2007 by Fabian embeded-mediaUDF ~~ Embed WMP, Quicktime and Flash in your Au3 appYABC ~~ Yet another Binary Clock 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