Jump to content
GoliaX

GUI showing wrong numbers

Recommended Posts

Hello all, I can't figure out why  this happens, maybe some of you find what i am doing wrong.

I have 2 inputs in my GUI, to end user can change mouse click delay and send key delay.

I have this as code:

Opt("MouseClickDownDelay", Number(GUICtrlRead($Inputm)))
Opt("MouseClickDelay", Number(GUICtrlRead($Inputm)))
Opt("SendKeyDownDelay", Number(GUICtrlRead($Inputk)))
Opt("SendKeyDelay", Number(GUICtrlRead($Inputk)))

I use 2 same valor inputs for these 4 opt.

Then when I press start script, the log GUICrtEdit shows  33 for MouseDelay and 37 for KeyDelay, then I thoght It is showing the number in hex, then i place Dec($Inputm) in CtrlSetData to show in log and it shows it in decimal but diferent number than what you choose in the GUI.

In real, even if you change the end user inputs, will always show 51 as mousedelay and 55 as keydelay. code:

 

Global $Inputk = GUICtrlCreateInput("40", 447, 223, 41, 22, BitOR($GUI_SS_DEFAULT_INPUT,$ES_CENTER,$ES_NUMBER))

Global $Inputm = GUICtrlCreateInput("50", 247, 223, 41, 22, BitOR($GUI_SS_DEFAULT_INPUT,$ES_CENTER,$ES_NUMBER))
Func _start_bot()
    If WinExists("example_window") = true Then
        Opt("MouseClickDownDelay", Number(GUICtrlRead($Inputm)))
        Opt("MouseClickDelay", Number(GUICtrlRead($Inputm)))
        Opt("SendKeyDownDelay", Number(GUICtrlRead($Inputk)))
        Opt("SendKeyDelay", Number(GUICtrlRead($Inputk)))
        GUICtrlSetData($label10, "["& _NowTime()&"]" & " ClickMouseDelay: " & Dec($Inputm) & @CRLF, "")
        GUICtrlSetData($label10, "["& _NowTime()&"]" & " KeySendDelay: " & Dec($Inputk) & @CRLF, "")
        sleep(1000)

 

support_autoit.JPG.d92becebeb8fc4fa6125bd5a584b918d.JPG

What am I doing wrong? Thank you in advance

Share this post


Link to post
Share on other sites

GoliaX,

Welcome to the AutoIt forum.

Those numbers are the ControlIDs of the inputs - you need to display their content.

And unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game automation - and then you will understand why you will get no further help and this thread will now be locked.

See you soon with a legitimate question I hope.

M23


Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
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, edit and colour 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
Guest
This topic is now closed to further replies.

×
×
  • Create New...