Sign in to follow this  
Followers 0
Pakku

Autoit Presentation For School

10 posts in this topic

#1 ·  Posted (edited)

hi,

for school i will teach autoit for some classmates

does any of you have some idees or usefull scripts i can use or a think i have to know or a thing they (my classmates) have to know?

thanks

Edited by Pakku

Share this post


Link to post
Share on other sites



Hi,

first of all, do you have any AutoIt experience?

I would start with easy scripts, that start a programm and type something. May be first a little messagebox that asks if you want to start this script.

I think, that the AutoIt v3 example Calculator is very useful:

-----------------------------------------------------------------------------------

;

; AutoIt Version: 3.0

; Language: English

; Platform: Win9x/NT

; Author: Jonathan Bennett (jon@hiddensoft.com)

;

; Script Function:

; Plays with the calculator.

;

; Prompt the user to run the script - use a Yes/No prompt (4 - see help file)

$answer = MsgBox(4, "AutoIt Example (English Only)", "This script will run the calculator and type in 2 x 4 x 8 x 16 and then quit. Run?")

; Check the user's answer to the prompt (see the help file for MsgBox return values)

; If "No" was clicked (7) then exit the script

If $answer = 7 Then

MsgBox(0, "AutoIt", "OK. Bye!")

Exit

EndIf

; Run the calculator

Run("calc.exe")

; Wait for the calulator become active - it is titled "Calculator" on English systems

WinWaitActive("Calculator")

; Now that the calc window is active type 2 x 4 x 8 x 16

; Use AutoItSetOption to slow down the typing speed so we can see it :think:

AutoItSetOption("SendKeyDelay", 400)

Send("2*4*8*16=")

Sleep(2000)

; Now quit by sending a "close" request to the calc

WinClose("Calculator")

; Now wait for calc to close before continuing

WinWaitClose("Calculator")

; Finished!

-------------------------------------------------------------------------------

Yu should show some basic commands, probably write a little script and give some example where to use AutoIt.

Share this post


Link to post
Share on other sites

Also make sure you give tutorial links and maybe do the Autoit 1-2-3 thing

Good tutorial website:

http://www.hiddensoft.com/autoit3/docs/

also try the FAQs on this forum

Share this post


Link to post
Share on other sites

How mutch time do you have?

Start with the teaser. A simple program doing somthing usefull.

Then explain the core of any programing language. That is:

* Variables to store and use results (declaration, how to assigne and get the values)

* Branching: If .. Then .. Else .. EndIf; Celect Case and Switch (start with If...)

* Loops: For ... Next; Do ... Until; While ... Wend

* Functions: Why use them, how to define them

While you do this use the excelent AutIt help file all the time for each item you present. It will teach people where to find information.

Get on with the nifty grifty AutoIt functions..:think:)

Do prepeare, if it is possible to fuck up you will do it at a presentation :">

Best of lucks with your teaching experience. !

Share this post


Link to post
Share on other sites

...first of all, do you have any AutoIt experience?...

You could always glance at arjan's past posts :-)

arjan,

Maybe you could put your scripts:

http://www.autoitscript.com/forum/index.ph...showtopic=19411

http://www.autoitscript.com/forum/index.ph...showtopic=19462

and others onto a CD like Uten posted to chat

Uten,

Run from CD - good idea.


[size="1"][font="Arial"].[u].[/u][/font][/size]

Share this post


Link to post
Share on other sites

thanks all, those are great idees

i will use moste of them

thanks

@Satyrn

my experience is pretty good.

Share this post


Link to post
Share on other sites

thanks all, those are great idees

i will use moste of them

thanks

@Satyrn

my experience is pretty good.

I think this is a great idea!

Make an ISO of it, spit it into 100Mb chunks using WinRar, upload to somewhere like http://rapidshare.de/ or maybe seed it using Bittorrent?

All the people here could contribute Howto`s UDF`s etc,etc, maybe?

Would need a good search tool though..

This program is great for doing tutorials http://www.debugmode.com/wink/ you can even record sound with V2.0 :think:


2015 - Still no flying cars, instead blankets with sleeves.

Share this post


Link to post
Share on other sites

I like examples that are simple but useful in the real world.

The following functions are some of the more useful ones

MsgBox / InputBox - basic

Run - basic

WinMove - easy to understand

ClipGet / ClipPut - poorman's I/O

FileWriteLine - basic file I/O

HotKeySet - useful

StringReplace - very useful along with the other String functions

I frequenly use the program StartupCPL but am annoyed that it (1) always opens in a small window and (2) opens to the previously open tab instead of the vert first tab. I can use a simple AutoIt script to launch StartupCPL and resolve both problems.

; First attempt - just run and resize
Run("C:\StartupCPL.exe")
WinWait("Startup Control Panel")
WinMove("Startup Control Panel", "", 50, 50, 700, 400)

; Second attempt - use varaible, run and resize, select first tab
$title = "Startup Control Panel"
Run("C:\StartupCPL.exe")
WinWait($title)
WinMove($title, "", 50, 50, 700, 400)
Send("^{Home}");Ctrl+Home selects first tab (easier than ControlCommand...)

I recently had to add a lot of acronym tags to some webpages. I used code similar to the following to automate the process.

; Adds acronym tags to the contents of the clipboard

$clipboard = ClipGet()
ClipPut( Acronymify($clipboard) )
Exit

; The primary function which uses the acro helper function to make the code cleaner
Func Acronymify($text)
    acro($text, "AACRAO",   "American Association of Collegiate Registrars and Admissions Officers")
    acro($text, "AAUP", "American Association of University Professors")
    acro($text, "ACRL", "Association of College & Research Libraries")
;...
    acro($text, "UAC",  "University Assessment Committee")

    Return $text
EndFunc

; Case-sensitive replacement of all occurrences
; Maybe not the best example since it uses ByRef....
Func acro(ByRef $a, $acronym, $meaning)
    $a = StringReplace($a, $acronym, '<acronym title="' & $meaning & '">' & $acronym & '</acronym>', 0, 1)
EndFunc

Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!

Share this post


Link to post
Share on other sites

I think this is a great idea!

Make an ISO of it, spit it into 100Mb chunks using WinRar, upload to somewhere like http://rapidshare.de/ or maybe seed it using Bittorrent?

All the people here could contribute Howto`s UDF`s etc,etc, maybe?

Would need a good search tool though..

This program is great for doing tutorials http://www.debugmode.com/wink/ you can even record sound with V2.0 :think:

I created an ISO with AutoIT3 Prod & Beta + Scite on it with autorun.inf starting a modified version of my memkey script, and its 19Mb, when RARed its only 7.7Mb..

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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