Search found 291 matches

by colt
07 Sep 2021, 15:44
Forum: Ask for Help (v1)
Topic: Running into trouble when converting vba code Topic is solved
Replies: 4
Views: 511

Re: Running into trouble when converting vba code Topic is solved

For anyone else interested in this, I found that you have to pass comvar element to this function. It is not documented this way, and the returned object is empty. But it does not crash ahk now. Probably need to pass it a specific object... swModel := swApp.activeDoc pgOut := comVar(varType:=9) swPa...
by colt
07 Sep 2021, 10:44
Forum: Ask for Help (v1)
Topic: vba to ahk conversion, help with usage of comvar()
Replies: 4
Views: 648

vba to ahk conversion, help with usage of comvar()

I am trying to convert my vba macro to ahk for exporting pdfs. So far I am able to get it to export with all the pages. Now I need to specify which pages to export which is giving me some trouble. swApp := getSolidworksHandle() ;get com object for active solidworks session swDrawing := swApp.activeD...
by colt
02 Sep 2021, 11:55
Forum: Ask for Help (v1)
Topic: Navigating object uisng string Topic is solved
Replies: 2
Views: 258

Navigating object uisng string Topic is solved

Right now this is the code I use to navigate and object when using variable as key. Is there a simpler way? c := new test inputKey := "obj.deep.deepParam" obj := c for index, param in strSplit(inputKey,".") { obj := obj[param] } msgbox % obj class test { __new() { this.var := "hi" this.obj := {param...
by colt
26 Aug 2021, 12:07
Forum: Ask for Help (v1)
Topic: Jumping cursor to other monitor
Replies: 15
Views: 1405

Re: Jumping cursor to other monitor

Here is what I use for multi monitor tabbing. Not sure if it adds anything to what was already said. It can work with any amount of monitors and resolutions. Nothing needs to be hard coded unless you want custom tab order. global hCB := RegisterCallback("EP", "F", 4, 0) global hList := "" CoordMode,...
by colt
11 Aug 2021, 19:23
Forum: Ask for Help (v1)
Topic: sendmessage failing when called from php Topic is solved
Replies: 3
Views: 326

Re: sendmessage failing when called from php Topic is solved

Turns out it had to do with which user the webserver was being launched under. I was using xampp to automatically start the server but it was creating the apache process under the system user. This shielded it from all windows that were created under my user. To fix I manually launched httpd.exe loc...
by colt
10 Aug 2021, 22:34
Forum: Ask for Help (v1)
Topic: How to differentiate multiple connected process when it return the same parent PID?
Replies: 1
Views: 253

Re: How to differentiate multiple connected process when it return the same parent PID?

I have no experience with this program but maybe try another approach. Could you find which PID is using which port and then kill the HD-Player directly? Use the netstat -ano command from here https://docs.microsoft.com/en-us/troubleshoot/windows-server/performance/determine-which-program-use-block-...
by colt
10 Aug 2021, 22:07
Forum: Ask for Help (v1)
Topic: sendmessage failing when called from php Topic is solved
Replies: 3
Views: 326

Re: sendmessage failing when called from php Topic is solved

what is a 4 doing in the wParam of WM_COPYDATA I was using that parameter to control a switch inside reciever.ahk to specify which functionality was being triggered. It did'nt seem to care what value I put in there so I just left it at 0 for a while until I thought of passing extra information thro...
by colt
10 Aug 2021, 15:15
Forum: Ask for Help (v1)
Topic: sendmessage failing when called from php Topic is solved
Replies: 3
Views: 326

sendmessage failing when called from php Topic is solved

I have a web server where I need to launch an ahk script and get the return value inside php. I am able to do this with simple scripts. However, I am having trouble with sendMessage when my script is launched from the php environment. When launched manually everything works as expected, but once cal...
by colt
26 Jul 2021, 09:54
Forum: Ask for Help (v1)
Topic: Open Novell Tray from system tray
Replies: 3
Views: 193

Re: Open Novell Tray from system tray

Use keyboard shortcuts found here https://superuser.com/questions/105773/how-to-access-the-system-tray-using-the-keyboard to navigate the menu to your command.
Then make a script that does those shortcuts for you. Finally assign it a hotkey.
by colt
11 May 2021, 13:35
Forum: Ask for Help (v1)
Topic: Custom button in explorer
Replies: 3
Views: 197

Re: Custom button in explorer

Thanks for the suggestions, verb is the term I needed to look up. I can't change the interface because my coworker using this script doesn't adjust to change very well. I managed to enable the verb button by adding this registry key. Computer\HKEY_CLASSES_ROOT\Applications\PDFViewer.exe\shell\print\...
by colt
11 May 2021, 09:26
Forum: Ask for Help (v1)
Topic: Custom button in explorer
Replies: 3
Views: 197

Custom button in explorer

I have created a pdf viewer exe that shows the pdf in an activex gui control. This script replaced adobe viewer as the default program. Everything is great, except the button to print directly from explorer is missing. I think it is possible to attach this custom command to my exe, but it looks like...
by colt
07 May 2021, 10:33
Forum: Ask for Help (v1)
Topic: Running into trouble when converting vba code Topic is solved
Replies: 4
Views: 511

Running into trouble when converting vba code Topic is solved

I am converting this vba code to run in ahk. Set swApp = Application.SldWorks 'Dim swModel As SldWorks.ModelDoc2 Set swModel = swApp.ActiveDoc Set pg = swModel.Extension.GetPackAndGo So far I've been able to convert most of my macros over to ahk, but this one is giving me trouble. It seems that the ...
by colt
30 Apr 2021, 10:01
Forum: Ask for Help (v1)
Topic: Reading Serial Port COM RS485 via USB CDC with AHK
Replies: 5
Views: 1535

Re: Reading Serial Port COM RS485 via USB CDC with AHK

If it is just sending characters over the COM port then the script from here https://www.autohotkey.com/boards/viewtopic.php?p=305415#p305415 might work.
by colt
28 Apr 2021, 11:59
Forum: Ask for Help (v1)
Topic: optimizing a program
Replies: 2
Views: 196

Re: optimizing a program

very cool, thanks for your insight. This is a really good starting point.
by colt
27 Apr 2021, 16:24
Forum: Ask for Help (v1)
Topic: optimizing a program
Replies: 2
Views: 196

optimizing a program

I would like to record how my application is running to find optimization points and understand how new code is effecting performance. Ideally I want to record which subs and functions are called and how long each takes to execute. Is there a tool already made to do this? I am thinking that the list...
by colt
26 Apr 2021, 13:40
Forum: Ask for Help (v1)
Topic: Does this DllCall to GetCursorPos work for negative mouse coordinates? Topic is solved
Replies: 4
Views: 656

Re: Does this DllCall to GetCursorPos work for negative mouse coordinates? Topic is solved

dont think so DllCall("GetCursorPos", "uint64*", v:=0), _x := 0xFFFFFFFF & v, _y := v >> 32 coordMode mouse,screen mouseGetPos realX,realY MsgBox % _x ", " _y . "`n" . realX . ", " . realY --------------------------- AHK_CQT_2157500 --------------------------- 4294966810, 841 -486, 841 -------------...
by colt
26 Apr 2021, 09:34
Forum: Ask for Help (v1)
Topic: Using microsoft surface as wacom tablet interface
Replies: 0
Views: 142

Using microsoft surface as wacom tablet interface

I am trying to to use my surface tablet as a touch interface for my main desktop computer for picture editing. I ended up modifying the chat example from here https://autohotkey.com/board/topic/53827-ahksock-a-simple-ahk-implementation-of-winsock-tcpip/ to send position and mouse events. However, th...
by colt
14 Apr 2021, 14:08
Forum: Ask for Help (v1)
Topic: spawning com objects naturally
Replies: 2
Views: 129

Re: spawning com objects naturally

Thanks for the suggestion. My current solution is to connect to existing instance. I always have to run the following code to guarantee the program will interact normally with the rest of the system once my script is done. I was wondering if my catch statement could be transferred to a com call. get...
by colt
14 Apr 2021, 13:02
Forum: Ask for Help (v1)
Topic: spawning com objects naturally
Replies: 2
Views: 129

spawning com objects naturally

I am trying to control my 3d modeling program with com and ran into some issues. If I spawn the application with comObjCreate("SldWorks.application") it creates creates an instance of the application, but it does not behave normally. When I double click files that should open in this application the...
by colt
10 Apr 2021, 01:36
Forum: Ask for Help (v1)
Topic: using the dropbox api Topic is solved
Replies: 3
Views: 378

Re: using the dropbox api Topic is solved

I transferred some of the functionality over to the v2 api. It is not much, but it can do a few basic things. It should be pretty easy to expand on if any other api calls are needed.

https://github.com/coltEli/ahkDropboxSDK

Go to advanced search