Jump to content
Sign in to follow this  
erezlevi

script to run on the backround? is it possible?

Recommended Posts

erezlevi

hi,

is it possible to run a script in the backround of a user that doing something else with the computer?

meaning that if a script using moving a mouse, or moving to a certain pixels on the screen to execute something in the backround wont be interupted by the computer user?

thanks,

Share this post


Link to post
Share on other sites
PsaltyDS

hi,

is it possible to run a script in the backround of a user that doing something else with the computer?

Yes.

meaning that if a script using moving a mouse, or moving to a certain pixels on the screen to execute something in the backround wont be interupted by the computer user?

thanks,

Of course, if you want the script to use the mouse at the same time the user is, there will be a problem. What does it mean to run something "in the background" and yet need to operate the mouse on the desktop?

:P


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites
erezlevi

Yes.

Of course, if you want the script to use the mouse at the same time the user is, there will be a problem. What does it mean to run something "in the background" and yet need to operate the mouse on the desktop?

:P

Yes, is there a way to do it? if not, is there a way to move the mouse faster to the point I want?

Share this post


Link to post
Share on other sites
PsaltyDS

Yes, is there a way to do it? if not, is there a way to move the mouse faster to the point I want?

Yes, in the common use of the term, an AuotIt script can run completely "in the background". But you are sounding like you mean something else. What do you mean by "in the background"?

As for the mouse speed, read the help file under MouseMove(). A speed of 0 means instant move. You need faster than that? You'll have to hook the FTL drive up to your perpetual motion engine.

:P


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites
erezlevi

Yes, in the common use of the term, an AuotIt script can run completely "in the background". But you are sounding like you mean something else. What do you mean by "in the background"?

As for the mouse speed, read the help file under MouseMove(). A speed of 0 means instant move. You need faster than that? You'll have to hook the FTL drive up to your perpetual motion engine.

:P

OK, let me tell you what I am doing, I am using AutoIT in order to bring a screen up infront of a Call-Center agent.

his Softphone (computer telephony phone) is using Screen POPS to bring up a URL on their internal web database.

the softphone is attaching (like concatinating) the caller phone number to the URL for example if you dialed my call-center your Cell phone number will be attached to a URL: http://companyX.com/customersdatabase/info?tel=918872092

and it will lead to your page inside the company database, but what if you dial from a restricted number? then the Softphone application does not bring up the URL by itsown. so the AutoIT script is running on the backround, the PBX (telephone switch) is knowing you are calling from a restricted number so it is sending the agent a "0" instead of a number so it is now looks like: http://companyX.com/customersdatabase/info?tel=0, but the PBX knows to collect the customer number if no number is provided so its ask you to put in your telephone number for authorization so you put: 55555555 on the phone keypad.

so because there is a WingetTitle in the softphone application that shows: "Info: 55555555" then this script is doing it:

$i = 0

while $i <= 1

WinWait ("Info:")

$title = WinGetTitle("Info:","")

$InfoNumber=StringSplit($title,":")

sleep (3000)

MouseMove(108,43,0)

MouseDown("left")

MouseUp("left")

Send("{END}"&$InfoNumber[2])

Send("{ENTER}")

sleep (9000)

WinWaitNotActive ("Info:", 5)

Wend

now, I added as you suggested the MouseMove (108,43,0) so the mouse is moving to the URL faster then before and the http page looks like: http://companyX.com/customersdatabase/info?tel=0%20555555555. and with that I can handle. and move to the customer page.

The issue is that I was afraid that the Agent will play soliter or Mine games while the mouse is moving to the URL address on IE, so I needed to make it as fast as I can.

Thanks, now it is ok.

Share this post


Link to post
Share on other sites
PsaltyDS

The issue is that I was afraid that the Agent will play soliter or Mine games while the mouse is moving to the URL address on IE, so I needed to make it as fast as I can.

Thanks, now it is ok.

If you learn to use the IE.au3 UDF you can automate actions in IE without using the mouse at all.

...just say'n you might want to look at _IEAttach() and _IENavigate() in the help file. (Notice how often that pesky help file comes up?)

:P


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites
Demonic

You can also use the function ControlClick( to send mouse clicks to certain pixels on a window without ur cursor moving

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  

×