Possible to drag item from treeview without seeing it?

Get help with using AutoHotkey and its commands and hotkeys
Posts: 31
Joined: 20 Apr 2018, 20:44

Possible to drag item from treeview without seeing it?

12 Jun 2018, 21:25

I'm using jeeswg's code to get items in a treeview as seen here

however I am wondering if its possible to drag one of the treeview items somewhere just by having access to the treeview item.

For example in the tree below, once I expand parent #3 (Equipment) I am able to obtain information for parent 3 child 4 (01.0005.Rack-512.24.04: 512.24 FWD PATH 320) even though I cant see it on the screen without scrolling. for example I have access to the name of this tree item, its location etc. Is it possible to somehow make the mouse left click on this item and drag it, without first scrolling down.
ie the item is hidden and i want the mouse to drag it

Code: Select all

Gui, Add, TreeView
P1 := TV_Add("Plant Ownership")
P1C1 := TV_Add("Parent 1's first child", P1)  ; Specify P1 to be this item's parent.
P2 := TV_Add("Extra Atrributes")
P2C1 := TV_Add("Parent 2's first child", P2)
P2C2 := TV_Add("Parent 2's second child", P2)
P2C2C1 := TV_Add("Child 2's first child", P2C2)
P3 := TV_Add("Equipment")
P3C1 := TV_Add("01.0005.Rack-512.24.01: 512.24 FWD PATH 317", P3)
P3C1C1 := TV_Add("Attributes", P3C1)
P3C1C2 := TV_Add("Plant Ownership", P3C1)
P3C1C3 := TV_Add("Ports", P3C1)
P3C1C3C1 := TV_Add("NC4. status",P3C1C3)
P3C1C3C2 := TV_Add("OUT. status",P3C1C3)
P3C2 := TV_Add("01.0005.Rack-512.24.02: 512.24 FWD PATH 318", P3)
P3C2C1 := TV_Add("Attributes" ,P3C2)
P3C2C2 := TV_Add("Plant Ownership" ,P3C2)
P3C2C3 := TV_Add("Ports" ,P3C2)
P3C2C3C1 := TV_Add("NC4. status", P3C2C3)
P3C2C3C2 := TV_Add("OUT. status" , P3C2C3)
P3C3 := TV_Add("01.0005.Rack-512.24.03: 512.24 FWD PATH 319", P3)
P3C4 := TV_Add("01.0005.Rack-512.24.04: 512.24 FWD PATH 320", P3)

Gui, Show  ; Show the window and its TreeView.

GuiClose:  ; Exit the script when the user closes the TreeView's GUI window.

Return to “Ask For Help”

Who is online

Users browsing this forum: Bing [Bot], boiler, Clemens375, DooMWhite, JaydeNpie, Raymond888, slupka, Smile_, submeg, yhk and 52 guests