Sign in to follow this  
Followers 0

Input Field on Gui

5 posts in this topic

#1 ·  Posted

Hello all,

I am pretty new with AutoIT so please bear with me. I basically need to make and inputbox on the main gui itself. I have a working version of what I need to do, but currently it uses a pop-up inputbox. I was wondering if there is a way to enter the information directly into the main gui without having another window pop up to take the user's input. Any help would be much appreciated on this.

Thanks in advance.

Share this post


Link to post
Share on other sites



#2 ·  Posted

PPowerHouseK,

I assume you have been using InputBox - just create an input control on the GUI with GUICtrlCreateInput and use that instead. :x

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert - Easily convert date/time formats, including the language used
ExtMsgBox ------------- A highly customisable replacement for MsgBox
GUIExtender ----------- Extend and retract multiple sections within a GUI
GUIFrame -------------- Subdivide GUIs into many adjustable frames
GUIListViewEx -------- Insert, delete, move, drag, sort and edit ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ---------------- Scrolling tickertape GUIs
NoFocusLines --------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify -------------------- Small notifications on the edge of the display
Scrollbars -------------- Automatically sized scrollbars with a single command
StringSize -------------- Automatically size controls to fit text
Toast -------------------- Small GUIs which pop out of the notification area

Share this post


Link to post
Share on other sites

#3 ·  Posted

Thanks so much for the quick reply!

So I placed the following snippet in my gui code, but for some reason the value returned no matter what is entered, is 43.

;Name field
$who = GUICtrlCreateInput("Name",10,270,100)

Perhaps I am making a mistake with my syntax, I am not sure.

Share this post


Link to post
Share on other sites

#4 ·  Posted

PPowerHouseK,

The 43 is the ControlID of the input control. You need to code like this: :P

; Create the input control and get the ControlID
$hInput_Name = GUICtrlCreateInput("Name",10,270,100)

; Read the content of the control when you need it
$sName = GUICtrlRead($hInput_Name)

All clear now? :x

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert - Easily convert date/time formats, including the language used
ExtMsgBox ------------- A highly customisable replacement for MsgBox
GUIExtender ----------- Extend and retract multiple sections within a GUI
GUIFrame -------------- Subdivide GUIs into many adjustable frames
GUIListViewEx -------- Insert, delete, move, drag, sort and edit ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ---------------- Scrolling tickertape GUIs
NoFocusLines --------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify -------------------- Small notifications on the edge of the display
Scrollbars -------------- Automatically sized scrollbars with a single command
StringSize -------------- Automatically size controls to fit text
Toast -------------------- Small GUIs which pop out of the notification area

Share this post


Link to post
Share on other sites

#5 ·  Posted

I see what you did there. Thanks, yet again!

Also I just downloaded all those apps in your signature that I've been looking for, thanks for that.

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