Jump to content

Blocking keyboard and mouse whilst AutoIt installs application


Recommended Posts

Sorry for opening a number of threads in the last few days but I am having a few problems.

Now this problem is a bit funny. Basically I compiled two programs using AutoIt to block the keyboard and mouse. They are very simple and basic, but it does the job

The following code is compiled as blockMaK.exe

;Block Mouse
BlockInput ( 1 )
sleep ( 2147483647 )

The following code is compiled as unblockMaK.exe

;Unblock Mouse
ProcessClose ("blockMak.exe")

Now basically I have an AutoIt compiled script which is supposed to install FireFox. It does this just fine. However, I want to block the keyboard and mouse whilst it installs. It blocks it ok, but the main problem is AutoIt cannot click/send the fucntions to control the application setup whilst the mouse/keyboard is unblocked. I hope this makes sense. Here's a copy of the batch file just incase.

start %SystemDrive%\WindowsFirstRun\MaK\blockMak.exe  <- blocks mouse
start "XF" /wait %SystemDrive%\WindowsFirstRun\ff.exe <-AutoIt script to install FireFox
start %SystemDrive%\WindowsFirstRun\MaK\unblockMak.exe <- kill blockMak.exe

Edit: I just realised that I can actually add BlockInput to the install AutoIt script for firefox itself, and it installs fine without blocking the clicks in the installer, only else where!

Edited by av2606
Link to comment
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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...