Jump to content

is there a way to make autoit run another script...


Recommended Posts

this is an odd one..

I made a program, and it will load up and do it's thing, but I want that same script(or another) to constantly look to see if the start menu is open... and if so, close it... but if I need two scripts to do so, I want 1 script to create the other file and run it. :)

right now, on every other line of code I have the file checking...

[u][font="Century Gothic"]~я α и d γ ĵ . ċ . ѕ қ ϊ и и ε я~- My Programs -auto shutdownSleep funcdisallow programs[/font][/u]
Link to comment
Share on other sites

this is an odd one..

I made a program, and it will load up and do it's thing, but I want that same script(or another) to constantly look to see if the start menu is open... and if so, close it... but if I need two scripts to do so, I want 1 script to create the other file and run it. :)

right now, on every other line of code I have the file checking...

while ( WinActive("[TITLE: STARTMENU; CLASS: DV2ControlHost]", "") = 0 )
   do stuff...
wend

Should work. Though that's off the top of my head, so don't quote me on the format of the function.

the Run() command will run scripts, iirc. if you compile the script first, then it definitely will. Just remember your paths. Run( myScript.au3 ) only works if myScript.au3 is in the same folder or is in a folder in the PATH environment variable.

Edited by Ataraxzy
Link to comment
Share on other sites

Let me correct myself. Run() will NOT run .au3 scripts. compile them into .exe's first and THEN call Run().

if I am correct...if I use the

while ( WinActive("[TITLE: STARTMENU; CLASS: DV2ControlHost]", "") = 0 )

do stuff...

wend

it will stop my program from running and stick in the loop

see, I want the program I have to either...Create... a new file, then run it, or, have my currently already made file continuously check to see if its open, while continueing through the rest of the script.

btw, you can use

shellexecute("name.au3") to run files that are not .exe

[u][font="Century Gothic"]~я α и d γ ĵ . ċ . ѕ қ ϊ и и ε я~- My Programs -auto shutdownSleep funcdisallow programs[/font][/u]
Link to comment
Share on other sites

Yeah I just did basically this same thing by monitoring for a usb flash drive to be plugged in while running my other script. The best way I found was to make the usb script into an .exe and then call it from my main script.

Hope this helps.

Link to comment
Share on other sites

Yeah I just did basically this same thing by monitoring for a usb flash drive to be plugged in while running my other script. The best way I found was to make the usb script into an .exe and then call it from my main script.

Hope this helps.

I am trying to work around having 2 scripts, If I need two scripts (which I am pretty sure I do...) I'm curious if it is possible for my 1st script to create the monitoring one, then run it

[u][font="Century Gothic"]~я α и d γ ĵ . ċ . ѕ қ ϊ и и ε я~- My Programs -auto shutdownSleep funcdisallow programs[/font][/u]
Link to comment
Share on other sites

What was the non-malicious reason for blocking the Start menu again...? :)

What's wrong with just BlockInput(1)?

:)

whats that do? lol

I need the keyboard to be recognized, so I would need it constantly searching for the start menu to open, (start menu was an easy example)

any idea's?

Edited by ReaImDown
[u][font="Century Gothic"]~я α и d γ ĵ . ċ . ѕ қ ϊ и и ε я~- My Programs -auto shutdownSleep funcdisallow programs[/font][/u]
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
 Share

  • Recently Browsing   0 members

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