AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Iniread and Iniwrite with Checkbox o.o

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
ppeterpp



Joined: 08 Jul 2009
Posts: 61

PostPosted: Sat Oct 17, 2009 9:29 pm    Post subject: Iniread and Iniwrite with Checkbox o.o Reply with quote

Hi!
Please help me making this. (i can't do this bur i read the help)
Writeand read from inifile.
If rememberuser checkbox checked, save username and pass in inifile, and at the next login it stays checked and user/and pass is stay in too.
If remember unchecked, the saved user and pass not appears at the editbox
thanks for helping and sorry for my bad english
Code:
Login = LOGIN TO S-MINER
Gui, 2:Font,cFF0000,
Gui, 2:Color, 000000
Gui, 2:+ToolWindow
Gui, 2:Add, Edit,-Vscroll cBlack x80 y12 w80 h20 vUsrname
Gui, 2:Add, Edit,-Vscroll cBlack x80 y42 w80 h20 vpasswrd Password
Gui, 2:Add, Text, x12 y12 w70 h20, Username
Gui, 2:Add, Text, x12 y42 w70 h20, Password
Gui, 2:Add, Button, x170 y12 w70 h20 Default, Login
Gui, 2:Add, Button, x170 y42 w70 h20 , Cancel
Gui, 2:Add, Text, x12 y120 w70 h20, News
Gui, 2:Add, Edit, x10 y135 w230 h60 ReadOnly, %newsss%
Gui, 2:Add, Checkbox, x160 y80 Right vrememberuser, Remember
Gui, 2:Show, x299 y200 h200 w250, %Login%
Return
Back to top
View user's profile Send private message
Guest






PostPosted: Sat Oct 17, 2009 9:35 pm    Post subject: Reply with quote

using the checkbox output variable, use if-else
like:
Code:

if rememberuser = 1
{
msgbox, save in ini
IniWrite
}
 
Back to top
ppeterpp



Joined: 08 Jul 2009
Posts: 61

PostPosted: Sat Oct 17, 2009 9:36 pm    Post subject: Reply with quote

Anonymous wrote:
using the checkbox output variable, use if-else
like:
Code:

if rememberuser = 1
{
msgbox, save in ini
IniWrite
}
 


i tried this but it don't works :S:S
i can't make iniread and iniwrite method to work correct :S
Back to top
View user's profile Send private message
MasterFocus



Joined: 08 Apr 2009
Posts: 3035
Location: Rio de Janeiro - RJ - Brasil

PostPosted: Sat Oct 17, 2009 9:48 pm    Post subject: Reply with quote

Are you performing Gui, Submit?
_________________
"Read the manual. Read it again. Search the forum.
Try something before asking. Show what you've tried.
"

Antonio França
My stuff: Google Profile
Back to top
View user's profile Send private message Visit poster's website
ppeterpp



Joined: 08 Jul 2009
Posts: 61

PostPosted: Sun Oct 18, 2009 7:32 am    Post subject: Reply with quote

MasterFocus wrote:
Are you performing Gui, Submit?


Code:

Login = LOGIN TO S-MINER
Gui, 2:Font,cFF0000,
Gui, 2:Color, 000000
Gui, 2:+ToolWindow
Gui, 2:Add, Edit,-Vscroll cBlack x80 y12 w80 h20 vUsrname
Gui, 2:Add, Edit,-Vscroll cBlack x80 y42 w80 h20 vpasswrd Password
Gui, 2:Add, Text, x12 y12 w70 h20, Username
Gui, 2:Add, Text, x12 y42 w70 h20, Password
Gui, 2:Add, Button, x170 y12 w70 h20 Default, Login
Gui, 2:Add, Button, x170 y42 w70 h20 , Cancel
Gui, 2:Add, Text, x12 y120 w70 h20, News
Gui, 2:Add, Edit, x10 y135 w230 h60 ReadOnly, %newsss%
Gui, 2:Add, Checkbox, x160 y80 Right vrememberuser, Remember
Gui, 2:Show, x299 y200 h200 w250, %Login%
Return

2ButtonCancel:
MsgBox, 16,LOGIN TO S-MINER, Login Failed`n
2GuiClose:
2GuiEscape:
Gui, 2:Destroy
ExitApp
Return

2ButtonLogin:
Gui, Submit
UrlDownloadToFile,http://mmostuff.elementfx.com/botconnectionsql/auth.php?user=%Usrname%&pass=%passwrd%,test2
FileReadLine, OutputVar, test2, 1
FileDelete,test2
if Outputvar = 1
{
Gui, 2:Destroy
Goto, ALALALALA
}if Outputvar = 0
{
MsgBox, 16, Wrong Username/Password, Wrong Username/Password`n If you lost your access data please contact us!
ExitApp
}if Outputvar = 2
{
MsgBox, 16, User not activated, Your User is not activated`n Your user will be activated after your payment.
ExitApp
}else
{
MsgBox, 16, Can't connect to the server, Can't estabilish connection`nPlease check your internet connection or try again later.
ExitApp
}
ALALALALA:


my full login script looks like this, i only want to save login data with checkbox, and if checkbox unchecked the login data doesn't be saved.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group