therks Posted June 1, 2005 Posted June 1, 2005 Is there a way to set the data for slider controls that aren't part of an AutoIt made GUI? My AutoIt Stuff | My Github
GaryFrost Posted June 1, 2005 Posted June 1, 2005 (edited) Edit: Look at next post Edited June 3, 2005 by gafrost SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
GaryFrost Posted June 3, 2005 Posted June 3, 2005 Added GuiSlider UDF's, should do what you want to get done, they are in the latest beta. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
therks Posted June 3, 2005 Author Posted June 3, 2005 Well first off: Woot for gafrost! But is there any way to set sliders in other GUI's? Like say, the default Windows Volume Control (sndvol32.exe)? My AutoIt Stuff | My Github
GaryFrost Posted June 3, 2005 Posted June 3, 2005 I wrote those to work with the GUI and Windows for Slider Controls "Trackbar"here's the screen capture from the volume control>>>>>>>>>>>> Window Details <<<<<<<<<<<<<Title: Play ControlClass: Tray VolumeSize: X: 817 Y: 450 W: 81 H: 136>>>>>>>>>>> Mouse Details <<<<<<<<<<<Screen: X: 859 Y: 528Cursor ID: 2>>>>>>>>>>> Pixel Color Under Mouse <<<<<<<<<<<RGB: Hex: 0x808080 Dec: 8421504>>>>>>>>>>> Control Under Mouse <<<<<<<<<<<Size: X: 24 Y: 24 W: 30 H: 81Control ID: 1001ClassNameNN: msctls_trackbar321Text: Style: 0x5001061AExStyle: 0x00000004>>>>>>>>>>> Status Bar Text <<<<<<<<<<<>>>>>>>>>>> Visible Window Text <<<<<<<<<<<Volume&Mute>>>>>>>>>>> Hidden Window Text <<<<<<<<<<<as you can see it has the msctls_trackbar321 control which is the same in the examples. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
/dev/null Posted June 3, 2005 Posted June 3, 2005 Well first off: Woot for gafrost!But is there any way to set sliders in other GUI's? Like say, the default Windows Volume Control (sndvol32.exe)?<{POST_SNAPBACK}>Maybe like this?run("sndvol32.exe") WinWait("Volume Control") ControlSend("Volume Control", "", "msctls_trackbar322", "{PGUP}") sleep(1000) ControlSend("Volume Control", "", "msctls_trackbar322", "{PGUP}") sleep(1000) ControlSend("Volume Control", "", "msctls_trackbar322", "{PGUP}") sleep(1000) ControlSend("Volume Control", "", "msctls_trackbar322", "{PGDN}") sleep(1000) ControlSend("Volume Control", "", "msctls_trackbar322", "{PGDN}") sleep(1000) ControlSend("Volume Control", "", "msctls_trackbar322", "{PGDN}")CheersKurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *
therks Posted June 3, 2005 Author Posted June 3, 2005 I wrote those to work with the GUI and Windows for Slider Controls "Trackbar"here's the screen capture from the volume controlas you can see it has the msctls_trackbar321 control which is the same in the examples.<{POST_SNAPBACK}>Ah okay, sorry I just hadn't had the opportunity to grab the latest beta yet, so I didn't have a chance to test them. I just assumed that they were using AutoIt-GUI specific functions or something. My AutoIt Stuff | My Github
therks Posted June 6, 2005 Author Posted June 6, 2005 Your GuiSlider UDFs are missing one function, "GUICtrlSliderGetPos" I guess for AutoIt-made GUI's, you don't need this, thanks to GuiCtrlRead. But for other sliders I don't believe there's a way to get their current value. Global Const $TBM_GETPOS = $TWM_USER Func _GUICtrlSliderGetPos($h_slider) Local $ret $ret = DllCall("user32.dll", "int", "SendMessage", "hwnd", $h_slider, "int", $TBM_GETPOS, "int", 0, "int", 0) Return $ret[0] EndFunc ;==>_GUICtrlSliderGetPos My AutoIt Stuff | My Github
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now