Jump to content

Recommended Posts

Posted

So... I am very new at AutoIt, and I would like some advice and sites for where to start. I have an idea, but I would need to know how to code hibernation scripts/restarting pc, window selection and typing in window. And, if I have a script that should restart my computer and then do something else (like run program and then restart again), can I then put all in one scrip? Will the scrip continue to run where it stopped?

-CasterAnd

PS. I do NOT ask you to write a long reply with a tutorial, all I wish is some helpful websites (other than the AutoIt website itself), and I'll also go and look at example scripts. I think AutoIt will work very good for me, and when I am done with my project, I might post it to the Example Scripts forum section ;)

Posted (edited)

There is plenty of tutorials/examples in this forum. Spend some time reading help file.. Search for functions and try to build some code, put it here nad you will get alot of help from others as all people there are very nice and always helps you.

Edited by Edgaras
Posted

Thanks, Edgaras! I have figured out how to type in certain windows and select them, and timing stuff. But, how do I let the scrip wait until 10:00 AM before continuing?

Posted

The Wiki is a good source of information too.

My UDFs and Tutorials:

  Reveal hidden contents

 

Posted (edited)

Something like:

While 1
    If @HOUR >= 10 and @MIN >= 00 Then ExitLoop
Wend
; Continue your script
Edited by water

My UDFs and Tutorials:

  Reveal hidden contents

 

Posted (edited)

  On 6/18/2012 at 7:40 PM, 'water said:

Something like:

While 1
If @HOUR >= 10 and @MIN >= 00 Then ExitLoop
Wend
; Continue your script

I am noob in AutoIt, so.. I do not know what you are talking about. Are you reffering to the part where the script should continue after reboot? ;) EDIT: I forgot what I wrote earlier, Thanks for your help! I now understand..

And, another question, can I make a simple config file for my AutoIt script? That is my first step in my giant script project. Something like this: StartTimeHour: 10

StartTimeMinute: 0

StartTimeSecond: 0

which would be transferred into the script and then start the pc (or wake up) at Hour: 10, Minute 0 and Second 0 (10:00:00)?

Edited by CasterAnd
Posted

I referred to post #3: "But, how do I let the script wait until 10:00 AM before continuing?"

Now that I have read post #1 I see you need something different.

My UDFs and Tutorials:

  Reveal hidden contents

 

Posted

Alright, so I am downloading "Learning to script with AutoIt" and "AutoIt 1-2-3". I might now be able to write the beginning of my script. Maybe I should do something simple... "Hello world"?

Posted

  On 6/18/2012 at 7:49 PM, 'CasterAnd said:

And, another question, can I make a simple config file for my AutoIt script? That is my first step in my giant script project. Something like this: StartTimeHour: 10

StartTimeMinute: 0

StartTimeSecond: 0

which would be transferred into the script and then start the pc (or wake up) at Hour: 10, Minute 0 and Second 0 (10:00:00)?

Look into AutoIt's helpfile at IniRead() and IniWrite()

There are also examples ...

Posted

If your config file needs an extensive hierarchy, look into utilizing an xml config file over an ini file.

If it's a big project... and you're just starting AutoIt... expect it to be re-written at least twice ;)

  Reveal hidden contents

 

Posted (edited)

Alright - A little update: I did read about 30 pages about AutoIt (before I got tired), and now my only question is: How do I wake my pc up from hybernating? I have seen a script that does, but I didn't understand much of it (how to configurate it...). All I need, is a code that just wakes up the pc at a certain time, and if someone can help me how to change that time. I would like it to start at 10:00 (Digital clock, NO am/pm). I would then like to have a code that sets the pc to hybernate when the string is being "runned" (I would then use a timer that waits until the time it should hybernate the server, and then the string that stops the server should be started and... set the pc to hybernate.

EDIT:I now know how to hybernate the pc, I now only need to know how to wake it up!

Edited by CasterAnd
Posted

One thing that really helped me get a grasp on the syntax was knowing how to use the help file efficiently.

When starting off, you may find yourself gazing at a certain function, trying to remember it's parameters and thinking about how tedious it is to open the help file and search for the function and read about it.

Luckily for me, I encountered a post in the wild by jon that explained how a user can simply click the function in question, slap the [F-1] key and watch the help file magically appear in front of your very eyes as you watch it mystically switch right to the page with the function in question, explaining to you in great detail every little aspect of the function (well, at least sometimes) and even giving you an example of how to use it as if it can read your mind.

Posted

  On 6/18/2012 at 9:09 PM, 'ApudAngelorum said:

One thing that really helped me get a grasp on the syntax was knowing how to use the help file efficiently.

When starting off, you may find yourself gazing at a certain function, trying to remember it's parameters and thinking about how tedious it is to open the help file and search for the function and read about it.

Luckily for me, I encountered a post in the wild by jon that explained how a user can simply click the function in question, slap the [F-1] key and watch the help file magically appear in front of your very eyes as you watch it mystically switch right to the page with the function in question, explaining to you in great detail every little aspect of the function (well, at least sometimes) and even giving you an example of how to use it as if it can read your mind.

Yea, I have seen the help file very helpful. But, it should still be a string in AutoIt called Wake... which wakes the pc from hybernating/sleeping at a certain time
Posted

I am not 100% sure but I believe Task Scheduler in Windows will wake a computer to run a task so it could handle all of your scheduling and extra triggers.

Posted

I searched the forum for "hibernation" and found a few threads about the subject. Didn't they give you a solution?

My UDFs and Tutorials:

  Reveal hidden contents

 

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

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