barrikid Posted October 7, 2010 Share Posted October 7, 2010 I am wondering if there is the code for the Finder Tool in Auto3Info. I know that the author won't show his code, but if there is a snippet that is like that code. Basically, I need a small box like the Finder tool which you click, drag it over to a location, release the mouse, and then it would save the location. Mainly I don't know how to find when the mouse is released, and also I don't know what he used for the GUI Thanks, BK Link to comment Share on other sites More sharing options...
bo8ster Posted October 7, 2010 Share Posted October 7, 2010 I have not seen the source however I created something like it called 'Control Handle under mouse' which you can find in my sig. There is a freeze function in the Info Tool so it only works when you are moving the target, not the mouse. That may do what you wish. Post your code because code says more then your words can. SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y. Use Opt("MustDeclareVars", 1)[topic="84960"]Brett F's Learning To Script with AutoIt V3[/topic][topic="21048"]Valuater's AutoIt 1-2-3, Class... is now in Session[/topic]Contribution: [topic="87994"]Get SVN Rev Number[/topic], [topic="93527"]Control Handle under mouse[/topic], [topic="91966"]A Presentation using AutoIt[/topic], [topic="112756"]Log ConsoleWrite output in Scite[/topic] Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted October 7, 2010 Moderators Share Posted October 7, 2010 barrikid, You do not need the Au3Info code - this is really easy to code in AutoIt itself: #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> $hGUI = GUICreate("Position Test", 220, 50) $hLabel = GUICtrlCreateLabel("", 10, 10, 100, 30) GUICtrlSetFont(-1, 18) GUISetState() $hChild = GUICreate("X", 5, 5, -1, -1, BitOR($WS_POPUP,$WS_BORDER), $WS_EX_TOPMOST, $hGUI) GUICtrlCreateLabel("", 0, 0, 5, 5, -1, $GUI_WS_EX_PARENTDRAG) GUICtrlSetBkColor(-1, 0x00FF00) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $GUI_EVENT_PRIMARYUP $aMpos = MouseGetPos() GUICtrlSetData($hLabel, $aMpos[0] & "x" & $aMpos[1]) EndSwitch WEnd Just click on the small green GUI and drag it - when you let go of the mouse button, the mouse coordinates appear on the GUI. M23 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 columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
barrikid Posted October 12, 2010 Author Share Posted October 12, 2010 (edited) #include <GUIConstantsEx.au3>#include <WindowsConstants.au3>$hGUI = GUICreate("Posit ...This is pretty interesting, definitely a step forwardThanks,BK Edited October 12, 2010 by barrikid Link to comment Share on other sites More sharing options...
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