3nc5y9710n256b1t Posted January 3, 2009 Share Posted January 3, 2009 Hi I'm new to autoit. Where should I start? Link to comment Share on other sites More sharing options...
Bert Posted January 3, 2009 Share Posted January 3, 2009 Look in my signature for a link to AutoIt 1 2 3. It is a wonderful class that will teach you AutoIt, and makes it fun! Welcome to the Forum! The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Zedna Posted January 3, 2009 Share Posted January 3, 2009 Also don't miss "C:\Program Files\AutoIt3\autoit.chm" It's full of examples. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
3nc5y9710n256b1t Posted January 3, 2009 Author Share Posted January 3, 2009 I dont want to make another thead in this short timeframe becuase I think that would be spam and i cant edit my original post so i'm asking my question here. is there something like stringsplit("1234","") that would give me thia array? $aArray[0] = 2 $aArray[1] = "12" $aArray[2] = "34" ? Link to comment Share on other sites More sharing options...
BrettF Posted January 3, 2009 Share Posted January 3, 2009 (edited) I haven't looked for a function, but I made this... #include <Array.au3> $string = "1234567890" $array = _StringSplitBy($string, 2) _ArrayDisplay($array) Func _StringSplitBy($string, $count) $c = 1 $split = StringSplit($string, "") Local $rArray[UBound($split)] ConsoleWrite(UBound($split) & @CRLF) For $i = 1 To UBound($split) - 1 Step $count ConsoleWrite("I = " & $i & @CRLF) For $x = $i To $i + $count -1 ConsoleWrite("X = " & $x & @CRLF) $rArray[$c] &= $split[$x] Next $c += 1 Next ReDim $rArray[$c] $rArray[0] = $c - 1 Return $rArray EndFunc ;==>_StringSplitBy Also, check out my tutorial. The link is in my sig. Cheers, Brett Edited January 3, 2009 by BrettF Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
Achilles Posted January 3, 2009 Share Posted January 3, 2009 I dont want to make another thead in this short timeframe becuase I think that would be spam and i cant edit my original post so i'm asking my question here. is there something like stringsplit("1234","") that would give me thia array? $aArray[0] = 2 $aArray[1] = "12" $aArray[2] = "34" ?You could try using StringLeft and then stringTrimLeft (or right for both)... Short example to get you started $num = "1234" $first = StringLeft($num, 1) $num = StringTrimLeft($num, 1) $secondTwo = StringLeft($num, 2) ... My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
BrettF Posted January 3, 2009 Share Posted January 3, 2009 You could try using StringLeft and then stringTrimLeft (or right for both)... Short example to get you started $num = "1234" $first = StringLeft($num, 1) $num = StringTrimLeft($num, 1) $secondTwo = StringLeft($num, 2) ...Awesome. New method using StringMid() #include <Array.au3> $string = "1234567890" $array = _StringSplitBy($string, 2) _ArrayDisplay($array) Func _StringSplitBy($string, $count) Local $rArray[StringLen ($string)] Local $x = 1 For $i = 1 To StringLen ($string) Step $count $rArray[$x] = StringMid ($string, $i, $count) $x += 1 Next ReDim $rArray[$x] $rArray[0] = $x - 1 Return $rArray EndFunc ;==>_StringSplitBy Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
Zedna Posted January 3, 2009 Share Posted January 3, 2009 Another quick and dirty version from me :-) #include <array.au3> $string = "1234" $aArray = MyStringSplit($string) _ArrayDisplay($aArray) Func MyStringSplit($string) Local $len = StringLen($string) / 2 Local $aArray[$len + 1] $aArray[0] = $len For $i = 1 To $len $aArray[$i] = StringMid($string, $i*2-1, 2) Next Return $aArray EndFunc Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Andreik Posted January 3, 2009 Share Posted January 3, 2009 Hi I'm new to autoit.Where should I start?http://www.autoitscript.com/forum/index.ph...st&p=609033 When the words fail... music speaks. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now