Search found 105 matches
- 26 Oct 2016, 23:29
- Forum: Scripts and Functions (v1)
- Topic: Gui Windows Drag and Drop - Show Dropped Files and Folders Separately
- Replies: 1
- Views: 1864
Gui Windows Drag and Drop - Show Dropped Files and Folders Separately
Gui Windows Drag and Drop - Show Dropped Files and Folders Separately: ;if "FileExist( )" return value contains "D" Attribute, a Directory\Folder was dropped, otherwise, a File was dropped ;"RegEx" is case sensitive by default ("d" is not "D") ;if RegExMatch(FileExist(FilePath), "D") ;if "FileExist(...
- 26 Oct 2016, 11:38
- Forum: Ask for Help (v1)
- Topic: How to UnFocus All Controls from a Window?
- Replies: 4
- Views: 1587
Re: How to UnFocus All Controls from a Window?
How to UnFocus All Controls from a Window?
- 26 Oct 2016, 09:31
- Forum: Scripts and Functions (v1)
- Topic: [Function] Last Left Clicked Control [Function]
- Replies: 1
- Views: 1063
[Function] Last Left Clicked Control [Function]
32 bit unicode .exe file: Can't upload file directly to the forum, so, link from MediaFire (bug from the file below fixed): http://www.mediafire.com/file/iohoq5msnooiecc/Last_Left_Clicked_Control_-_32_bit_unicode.rar Contains a bug [if (A_ThisHotkey = "WheelDown" or "WheelUp")]: 32 bit unicode .exe ...
- 25 Oct 2016, 20:37
- Forum: Ask for Help (v1)
- Topic: AutoHotkey GUI: ListView, remove focus Topic is solved
- Replies: 6
- Views: 2605
Re: AutoHotkey GUI: ListView, remove focus Topic is solved
The code works only with the Script gui windows!imustbeamoron wrote:try adding this line after you show your gui, it worked in my test.
Code: Select all
DllCall("SetFocus", "Ptr", 0)
Do you know how to make it work with any windows? (non script windows?)
- 25 Oct 2016, 16:37
- Forum: Ask for Help (v1)
- Topic: How to UnFocus All Controls from a Window?
- Replies: 4
- Views: 1587
How to UnFocus All Controls from a Window?
How to UnFocus All Controls from a Window?
- 24 Oct 2016, 12:30
- Forum: Ask for Help (v1)
- Topic: (SOLVED) Gui ListView Control - Column Header Right or Double Right Click!
- Replies: 19
- Views: 5702
Re: (SOLVED) Gui ListView Control - Column Header Right or Double Right Click!
Found a bug: Columns Header too much to the right can't be right clicked \ Edited \ Removed Fix Found: "MouseGetPos, , , WinId, ControlType" should be replaced by "MouseGetPos, , , WinId, ControlType, 1" The Function amended: GuiContextMenu: ;________________Gui Context Menu______________ ;R_EventIn...
- 23 Oct 2016, 16:52
- Forum: Ask for Help (v1)
- Topic: Avoid declaring Global Variables Inside functions by declaring Static Variables instead
- Replies: 35
- Views: 7641
Avoid declaring Global Variables Inside functions by declaring Static Variables instead
This is an example showing how to make the "Main Script" to get "Static Variables" values from functions, avoiding so declaring "Global" variables inside functions! Test Function Example: loop, 10 Test( ) msgbox, % Test("Addition") "`n`n" Test("Test") "`n`n" Test("Auto") "`n`n" Test("Code") "`n`n" T...
- 22 Oct 2016, 17:01
- Forum: Scripts and Functions (v1)
- Topic: OnMessage Alternative for Hotkeys!
- Replies: 4
- Views: 1609
Re: OnMessage Alternative for Hotkeys!
You only need to put it in a function with a Static initializer. Oops, Totally forgot about that, but anyway,they are all small pieces of code! Only Gui Windows: GroupAllScriptGuiWindows( ) ;___________ Group All Gui Windows belonging to the script's process (Function) __________ { Static RunAtScri...
- 22 Oct 2016, 13:58
- Forum: Scripts and Functions (v1)
- Topic: OnMessage Alternative for Hotkeys!
- Replies: 4
- Views: 1609
Re: OnMessage Alternative for Hotkeys!
; Match all GUI windows belonging to the script's process. GroupAdd, AllScriptGuiWindows, % "ahk_pid " DllCall("GetCurrentProcessId") . " ahk_class AutoHotkeyGUI" Thanks for the code, but I still prefer mine since it can be put at the end of the script! (I like to put these kind of codes at script'...
- 21 Oct 2016, 23:27
- Forum: Scripts and Functions (v1)
- Topic: OnMessage Alternative for Hotkeys!
- Replies: 4
- Views: 1609
OnMessage Alternative for Hotkeys!
This code should be copy/pasted at the end of any desired script: #IfWinActive ahk_group AllScriptGuiWindows ;__________ Hotkeys below only valid for "AllScriptGuiWindows"_____________ ;*** Any desired Hotkeys to be used with script Gui windows only, should be put here! *** #IfWinActive ;___________...
- 21 Oct 2016, 10:22
- Forum: Ask for Help (v1)
- Topic: How to get the focused control from an inactive window?
- Replies: 1
- Views: 482
How to get the focused control from an inactive window?
How to get the focused control from an inactive window?
- 20 Oct 2016, 18:43
- Forum: Ask for Help (v1)
- Topic: How to get replies from Windows?
- Replies: 1
- Views: 613
How to get replies from Windows?
How to get replies from Windows? Something like this: ~WheelDown:: ToolTip, %ErrorLevel% return ErrorLevel = 0 (Nothing was done!) ErrorLevel = 872783727382 (Vertical Scroll bar moved down) ErrorLevel = 443535242662 (Drop Down List option changed) ErrorLevel = 1 (something was done!) etc, etc, etc ...
- 18 Oct 2016, 18:57
- Forum: Ask for Help (v1)
- Topic: How to verify if a control contains or not vertical\horizontal scrollbars?
- Replies: 3
- Views: 980
Re: How to verify if a control contains or not vertical\horizontal scrollbars?
Function based on the code above! "Control" and "Window" parameters added! The function returns "VH" if control contains vertical and horizontal scroll bars, "V" if control contains only vertical scroll bar, "H" if control contains only horizontal scroll bar or "blank" if control contains no scroll ...
- 17 Oct 2016, 19:43
- Forum: Ask for Help (v1)
- Topic: How to verify if a control contains or not vertical\horizontal scrollbars?
- Replies: 3
- Views: 980
Re: How to verify if a control contains or not vertical\horizontal scrollbars?
Found this on internet: if (ControlStyle & 0x100000) ;check for "horizontal" scroll bar. HBar = Yes ;if control contains "horizontal" scroll bar, "HBar = Yes" if (ControlStyle & 0x200000) ;check for "vertical" scroll bar. VBar = Yes ;if control contains "vertical" scroll bar, "VBar = Yes" The codes ...
- 17 Oct 2016, 11:56
- Forum: Ask for Help (v1)
- Topic: How to verify if a control contains or not vertical\horizontal scrollbars?
- Replies: 3
- Views: 980
How to verify if a control contains or not vertical\horizontal scrollbars?
How to verify if a control contains or not vertical\horizontal scrollbars?
- 13 Oct 2016, 23:19
- Forum: Scripts and Functions (v1)
- Topic: [Functions] Get Focused Control - ClassNN - Hwnd - Text - List [Functions]
- Replies: 2
- Views: 5090
[Functions] Get Focused Control - ClassNN - Hwnd - Text - List [Functions]
All in One: GetFocusedControl(Option := "") { ;"Options": ClassNN \ Hwnd \ Text \ List \ All GuiWindowHwnd := WinExist("A") ;stores the current Active Window Hwnd id number in "GuiWindowHwnd" variable ;"A" for Active Window ControlGetFocus, FocusedControl, ahk_id %GuiWindowHwnd% ;stores the classnam...
- 12 Oct 2016, 13:59
- Forum: Ask for Help (v1)
- Topic: Gui Window Events Dynamic Labels \ Subroutines?
- Replies: 2
- Views: 903
Gui Window Events Dynamic Labels \ Subroutines?
Gui Window Events Dynamic Labels \ Subroutines not working! %MainGui%buttonclose: %MainGui%guiclose: gui, 2:Default if A_DefaultGui = 1 MainGui = ;blank else MainGui = %a_Defaultgui% gui, +HwndGuiId gui, show, w300 h200, Name Id - %GuiId% - %MainGui% - %MainGui% gui, add, button, , close return %Mai...
- 09 Oct 2016, 11:59
- Forum: Scripts and Functions (v1)
- Topic: [Workaround] Gui Windows - Multi Default Buttons [Workaround]
- Replies: 0
- Views: 1149
[Workaround] Gui Windows - Multi Default Buttons [Workaround]
A workaround that makes "Enter" key press to trigger the Gui Window "Default Button" action, or, it makes "Enter" key press to trigger another button action depending on the Gui window current focused control, without changing the Gui window "Default Button"! workaround Example: ;by "Shadowpheonix "...
- 09 Oct 2016, 09:51
- Forum: Scripts and Functions (v1)
- Topic: [Functions] Gui Windows - Get current Default Button - Get current Button with BS_DEFPUSHBUTTON style [Functions]
- Replies: 0
- Views: 896
[Functions] Gui Windows - Get current Default Button - Get current Button with BS_DEFPUSHBUTTON style [Functions]
Get current Default Button: ;by "just me" ;https://autohotkey.com/boards/viewtopic.php?f=5&t=23541 GuiGetDefaultButton(Option = "") ;_________________ Get Gui Default Button (Function) ________________________ { ; Retrieves the Name and\or HWND Id Number of the current "Default Button" (+Default) fr...
- 07 Oct 2016, 21:09
- Forum: Ask for Help (v1)
- Topic: How to get the current gui default button? Topic is solved
- Replies: 35
- Views: 8840
Re: How to get the current gui default button? Topic is solved
I usually do something like this... It works like a charm! Here is my code example using your method (just a little bit modified): ;Instead using "ClassNN", I prefer to use "Hwnd" (prevents desynchronizations if controls are added or removed) ;"#IfWinActive" in use ("Enter" Hotkey only valid for Gu...