Jump to content
Macro Express Forums

Trigger A Macro On Another Computer On Network


randallc

Recommended Posts

Hi, I hope this is not silly question;

I have two separate computers on the network, both running macro express. I would like to trigger a macro to run on the another computer, computer2, when I'm sitting at a different desk, computer1.

 

Is this just a silly question and it should be obvious, or is it not possible? I am flummoxed. I have read the macro express book, and have not seen any reference to this. Can anyone help?

Thanks very much, Randall Clapp.

Link to comment
Share on other sites

You are correct, Macro Express does not have any commands to do this directly. However, you can write some macros that will accomplish the task.

 

On the 'remote' computer, create a Scheduled Macro that looks for the existence of specific 'trigger' files. Then, when the files are found, run the appropriate macro.

 

On the 'local' computer, create one or more macros that map a network drive and create a 'trigger' file on the 'remote' computer.

 

Set the schedule of the macro on the remote computer for the frequency you want to check. You could check as often as every second but the more often you check the more CPU cycles you will use.

 

Here is a untested example:

 

Macro for the remote computer:

// Macro for 'Remote' computer

// Check for trigger file for MacroOne
If File Exists "MacroOne"
 Macro Run: MacroOne
 // Delete the file that triggered this macro
 Wait for File Ready: "MacroOne"
 Delete File or Files: "MacroOne"
End If

// Check for trigger file for MacroTwo
If File Exists "MacroTwo"
 Macro Run: MacroTwo
 // Delete the file that triggered this macro
 Wait for File Ready: "MacroTwo"
 Delete File or Files: "MacroTwo"
End If

Macro for the 'local' computer:

// Macro for 'Local' computer to trigger MacroOne on remote computer

// Establish a network connection
Variable Set String %T1% "AnyValue"
Network Connect: H: to \\IssServer\c
// Set the path in the Variable Modify String command to match the folder
//   and filename the macro on the remote computer is looking for.
Variable Modify String: Save %T1% to Text File

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...