Jump to content
Macro Express Forums

Mouse Blocking Solution


David Moen
 Share

Recommended Posts

I've seen a few requests for a mouse blocking solution on this forum, so I'll share mine. I had a friend write a little program to disable/enable the mouse. I then wrote a few macros to automate the program to be used when needed.

 

To use this in you own macros, unzip the attached file. Create a folder called TNT Mouse Disabler at C:\Program Files\TNT Mouse Disabler and put the TNTMouseDisabler.exe file in the folder. Import the macros from the Mouse.mex macro file into you macro file. In the macros that you wish to block the mouse from working, add the Log Errors command (check Use Default Log and Do not display error messages), then add the command Macro Run: Mouse Disable at the point you want the mouse to be blocked and add the command Macro Run: Mouse Enable at the point you want the mouse to be unblocked. If the macro gets aborted while the mouse is disabled the Errors will get logged and no message will appear, then the Mouse Enable After Abort macro will run automatically and re-enable the mouse and display a message that the macro was aborted and the mouse was re-enabled. The message also gives the user the option to view the error log.

 

I hope this is useful to some of you. I use it all the time and it works very well.

 

David Moen

MouseDisable.ZIP

Link to comment
Share on other sites

  • 1 year later...
  • 2 years later...

This definitely what I'm looking for, except it's a shame the tntmousedisabler.exe has a dialog window instead of a simple command switch, aka... (tntmousedisabler -on / tntmousedisabler -off) or something...anyone know of an application or script that might work like that instead?

 

Has there been any progress on integrating this functionality into ME directly?

 

Any tips or suggestions would be much appreciated.

 

Thanks,

Tory

Link to comment
Share on other sites

Has there been any progress on integrating this functionality into ME directly?

 

I believe this function has been added into the new Pro version. I haven't tried it yet, I write macros for a living and I've been on vacation since before the Pro version came out. I'll probable give it a try after I get back to work in the new year.

 

David

Link to comment
Share on other sites

  • 10 months later...

I'm afraid I won't be much help. I know nothing of Delphi. I tried to do it today as my first-ever project with AutoIt. It should be a one-line AutoIt script: BlockInput(1) or BlockInput(0) to lock / unlock both the mouse and keyboard. But it's not working for me. I must be doing something wrong. I suppose I should just give in and install ME Pro, since we just upped our licenses to 100. But we're in the middle of rolling out a couple projects developed with ME3, and that's not a good time to rock the boat.

Link to comment
Share on other sites

I must say this solution has a couple of advantages over the one built into ME Pro. It blocks only the mouse, which may be a disadvantage for some. The biggest advantage is that the mouse blocking can be terminated with out terminating the macro that is running. I've done this many times on macros that are stuck waiting on something like a window or a control and some other window came to the front. Using the keyboard commands and/or terminating the mouse blocking allows me to correct the problem and let the macro finish. The ME Pro solution would kill the running macro to regain control of the mouse and keyboard. ME Pro would have been better if they allow you to block only the mouse in this case.

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...
 Share

×
×
  • Create New...