Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate

running AHK with remote desktop minimized?


  • Please log in to reply
11 replies to this topic
TeeJay
  • Guests
  • Last active:
  • Joined: --
Hi *,
I have following problem:

My AHK.exe runs fine, even when I start it remotely via "remote desktop".
But when I minimze the "remote desktop"-window, the AHK.exe stops and resumes working only after restoring the "remote desktop"-window.

My AHK.exe is physically located on the remote machine.
I start my AHK.exe manually in the "remote desktop"-window.
I do not log off, just minimize the "remote desktop"-window.

I searched the forum but did not find an answer to this scenario...
Closest description of my problem is that of bubamarkus, posted Thu Sep 01, 2005 10:39 pm, in "Remote Desktop problem", but no really solution was given.

Any solutions in the meantime?
Thanks in advance,
TeeJay

wOxxOm
  • Members
  • 371 posts
  • Last active: Feb 20 2015 12:10 PM
  • Joined: 09 Feb 2006
I suppose this:

RemoteAdmin server process launches a program on request of remote user (you). So R.A. is a parent process for AHK. Once you minimize your RA session client it signals the RA-server that. RA-server thinks now that since the client is minimized it does not need anything and to consume CPU power it halts any activity of itself and its child processes.

If I am right then either find a setting (may be hidden) for your RA server/client, or try to promote AHK processes into global context (seems like a virus?), or find another RA software

CraSH23000
  • Members
  • 40 posts
  • Last active: Apr 15 2013 06:03 AM
  • Joined: 22 Jun 2007
I also have had this problem, I thought putting my actual ahk script onto the system I was remote connecting to would solve the problem, but minimizing halts all progress.

So I just leave it un-maximized behind my other windows.

A solution would be very nice though.
Truth is truth, whether you believe it or not.

none
  • Guests
  • Last active:
  • Joined: --
I hate to say this on an AutoHotkey forum but Autoit can do it. I had the same problem with Remote Desktop and changed to Autoit - all works fine now. The code for Autoit was a little trickey for me sometimes but I got it done.

none
  • Guests
  • Last active:
  • Joined: --
just a little note about Autoit - it seems like the send commands didn't like to work in Remote Desktop when minimized but I got around that by using the ControlSend command.

I hope this helps someone

TeeJay
  • Guests
  • Last active:
  • Joined: --
Seems to be trickier than expected...

I tested running a batch script (copying a large file several times over and logging the number of the actual loop with time stamp), and that finished even when remote desktop window is minimized.

So it is NOT a (or any) remote process shutting down whenever remote desktop is minimized. It is AHK having this behaviour (maybe other processes too, though).

Still hoping for a solution............

  • Guests
  • Last active:
  • Joined: --
Autohotkey works fine when I minimize the remote window.
however when I disconnect but keep logged in on the system the scripts stop.
And I really need a fix for this since I will soon have to run some scripts as a sort of server. (to automaticly book emails in a ticketing system and send out emails from the ticketing system.

Does someone know a solution for that?

(I take over Windows XP computers lokated in an other country than we are located ourself)

Traderhut
  • Members
  • 11 posts
  • Last active: Aug 22 2008 06:45 PM
  • Joined: 05 Apr 2008
Well, I've been having the same problem, and I took a crazy approach...

There were two solutions actually..

I remote terminal'ed into Machine A, and using it, Remote terminaled into machine B which ran the script. On A, I left the window viewable (not minimized, as this will stop script running on B).

Then Disconnecting from A will not stop the script on B... Pretty crazy, but it works.

Option #2....

Install VMWare on Machine A... Run Script in VM on A... Script continues to run even if you disconnect from machine A....

Really want a AHK solution, as other processes continue to run just fine, and as someone pointed out, another scripter is able to get it to go...


-Chert

clackwell
  • Guests
  • Last active:
  • Joined: --
When using AutoHotkey or AutoIt scripts on remote computers that you access via Remote Desktop (RDP), remember not to use WinActivate, or else the scripts will hang on that command when the Remote Desktop window gets minimized or closed.

Use the ControlSend command instead of Send, then you don’t need to use WinActivate. AutoHotkey example:

ControlSend, Edit1, something to enter, Window Title

Sapient
  • Guests
  • Last active:
  • Joined: --
I found something that might allow it:

http://www.softtreet.../archive/51.htm

randallf
  • Members
  • 711 posts
  • Last active: Jan 07 2014 11:45 PM
  • Joined: 06 Jul 2009

When using AutoHotkey or AutoIt scripts on remote computers that you access via Remote Desktop (RDP), remember not to use WinActivate, or else the scripts will hang on that command when the Remote Desktop window gets minimized or closed.

Use the ControlSend command instead of Send, then you don’t need to use WinActivate. AutoHotkey example:

ControlSend, Edit1, something to enter, Window Title


Thank you, this may be a massive help to me. Having exactly the same problems with RDP.

jankiramanrai
  • Members
  • 6 posts
  • Last active: Aug 29 2012 09:41 AM
  • Joined: 29 Aug 2012
Hi All,

I had same problem and it got resolved using Control send,
But now I have another problem ,
When I am sending a path C:\test1_1 to textfield,
if remote machine is minimized the path is getting changed to C;\test1-1,
and if remote machine is not minimized it is entering corrrect value ,
I have no idea how colon is getting chnaged to semicolon,
or underscore is getting chnage dto dash(-).

Could any one help me out here?