Jump to content

What Is The Message?


Recommended Posts

I am trying to make my script as user friendly as possible. To that end I need to capture a user name early on in the scripting process and save it to be applied in an Oracle SQL Plus application later on. I set up the following scripts: I get the message box with the prompt to enter the user name as specified, however the third message box displays You have entered the user name $username instead of the information typed in the previous window, What have I done wrong? Also, if I click no I do not get a chance to correct the typed in information and the script does not stop.

$__msgbox = MsgBox ( 4, 'AOOA MIS Dept', 'This Script will install the Latest Version of Passport for Windows. Do you want to Continue?' )

if NOT ( $__msgbox = 7 ) then

BlockInput ( 0 )

$Username = InPutBox ("AOOA MIS Dept", "Please enter your user name for Passport for Windows. This is your first initial, last name.", (" "))

MsgBox (4, "AOOA MIS Dept", "You entered the user name" & "$username")

if not ($__msgbox = 7) Then

Link to comment
Share on other sites

  • Developers

anything between " " or ' ' is a literal....

so it should be :

MsgBox (4, "AOOA MIS Dept", "You entered the user name" & $username)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Thanks, you guys are great, this board responds faster than any other board I post on! Two things, how do I insert a space between the text "You entered the user name" and the name the user typed in and how do I loop back if they discover that they typed in the wrong name?

Link to comment
Share on other sites

  • Developers

Thanks, you guys are great, this board responds faster than any other board I post on! Two things, how do I insert a space between the text "You entered the user name"

are you serious ???

ok lets assume you are...

change:

"You entered the user name" & $username

to

"You entered the user name " & $username

loop till ok is clicked

$__msgbox = 7
While $__msgbox = 7
  $Username = InPutBox ("AOOA MIS Dept", "Please enter your user name for Passport for Windows. This is your first initial, last name.", (" ")) 
  $__msgbox = MsgBox (4, "AOOA MIS Dept", "You entered the user name " & "$username")
wend

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...