Jump to content

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Find out more here. X
X


Photo

Input Field on Gui


  • Please log in to reply
4 replies to this topic

#1 PPowerHouseK

PPowerHouseK

    Seeker

  • Active Members
  • 21 posts

Posted 11 January 2011 - 10:56 PM

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.







#2 Melba23

Melba23

    I'm old - what's your excuse?

  • Moderators
  • 20,855 posts

Posted 11 January 2011 - 10:59 PM

PPowerHouseK,

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

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

#3 PPowerHouseK

PPowerHouseK

    Seeker

  • Active Members
  • 21 posts

Posted 11 January 2011 - 11:17 PM

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.

#4 Melba23

Melba23

    I'm old - what's your excuse?

  • Moderators
  • 20,855 posts

Posted 11 January 2011 - 11:21 PM

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
StringSize - Automatically size controls to fit text                                                               ExtMsgBox - A user customisable replacement for MsgBox
Toast - Small GUIs which pop out of the Systray                                                                Marquee - Scrolling tickertape GUIs
Scrollbars - Automatically sized scrollbars with a single command                                   GUIFrame - Subdivide GUIs into many adjustable frames
GUIExtender - Extend and retract multiple sections within a GUI                                      NoFocusLines - Remove the dotted focus lines from buttons, sliders, radios and checkboxes
ChooseFileFolder - Single and multiple selections from specified path tree structure      Notify - Small notifications on the edge of the display
Date_Time_Convert - Easily convert date/time formats, including the language               GUIListViewEx - Insert, delete, move, drag, sort and edit ListView items

#5 PPowerHouseK

PPowerHouseK

    Seeker

  • Active Members
  • 21 posts

Posted 11 January 2011 - 11:35 PM

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.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users