Sign in to follow this  
Followers 0
peomalle

Disable Mouse Button, Run App, Re-enable Button

4 posts in this topic

What I would like to accomplish seems like it would be easy via AutoIt, but I'm sure there is more to it. Basically, I need to:

1) Disable the left mouse button (or even better, have the left mouse button take on the actions of the right mouse button)

2) Launch Windows Explorer (for file management)

3) Re-enable the left mouse button once Windows Explorer is closed.

At our company, Windows Explorer is notorious for the much too "quick and easy" way that files and folders can be accidentally moved from one part of the network drive to another causing much gnashing of teeth.

Any help would be greatly appreciated.

Thank you

Share this post


Link to post
Share on other sites



#3 ·  Posted (edited)

What I would like to accomplish seems like it would be easy via AutoIt, but I'm sure there is more to it. Basically, I need to:

1) Disable the left mouse button (or even better, have the left mouse button take on the actions of the right mouse button)

2) Launch Windows Explorer (for file management)

3) Re-enable the left mouse button once Windows Explorer is closed.

At our company, Windows Explorer is notorious for the much too "quick and easy" way that files and folders can be accidentally moved from one part of the network drive to another causing much gnashing of teeth.

Any help would be greatly appreciated.

Thank you

Windows Explorer

Run("explorer.exe")

Disable mouse and keyboard ; that disable all i'm sorry....

Blockinput(1)

And your script :

ProcessClose("explorer.exe");The process doesn't exist so disable input
Sleep(2000);Sleep 2 seconds for test and run explorer for unblock
Run("explorer.exe")

While 1
Sleep(250)
If Not ProcessExists("explorer.exe") Then;If explorer exists then...
Blockinput(1);Block input
Else
Blockinput(0);Unblock input if explorer exists
EndIf
WEnd

Here you have code for block mouse button : http://www.autoitscript.com/forum/index.ph...mp;#entry495252

Edited by FireFox

 

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.
Hardware : Intel(R) Core(TM) i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

 

Share this post


Link to post
Share on other sites

What I would like to accomplish seems like it would be easy via AutoIt, but I'm sure there is more to it. Basically, I need to:

1) Disable the left mouse button (or even better, have the left mouse button take on the actions of the right mouse button)

2) Launch Windows Explorer (for file management)

3) Re-enable the left mouse button once Windows Explorer is closed.

At our company, Windows Explorer is notorious for the much too "quick and easy" way that files and folders can be accidentally moved from one part of the network drive to another causing much gnashing of teeth.

Any help would be greatly appreciated.

Thank you

If @OSVersion <> "WIN_98" And @OSVersion <> "WIN_ME" Then

BlockInput(1)

EndIf

Run("explorer.exe")

WinWaitActive("[CLASS:CabinetWClass]") ; you will need to know what the explorer.exe class name is ... this is the vista class name

;other code you need to run before unblocking inputs

BlockInput(0)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0