Sign in to follow this  
Followers 0
JonathanChan

Multiply String?

7 posts in this topic

Hello,

I probably just dont' know the name of the function which is why i can't do what i want to do... but how do I make $var=j 10 times? (ie. $var=jjjjjjjjjj)... What my real purpose for asking is to add NULL characters to a file handler. I have to add the null characters based on filesize and it isn't 1 static amount of nulls...

Thanks,

Jonathan

Share this post


Link to post
Share on other sites



Hello,

I probably just dont' know the name of the function which is why i can't do what i want to do... but how do I make $var=j 10 times? (ie. $var=jjjjjjjjjj)... What my real purpose for asking is to add NULL characters to a file handler. I have to add the null characters based on filesize and it isn't 1 static amount of nulls...

Thanks,

Jonathan

If it's a number (j) then... $var *= Int($j)

For $iCC = 1 To 10
    $var &= 'String'
Next

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

is for efficient? I may need up to 500 null characters... seems like a lot of concating...

Share this post


Link to post
Share on other sites

For $iCC = 1 To 500

$var &= 'j'

Next

Kurt


Awaiting Diablo III..

Share this post


Link to post
Share on other sites

i know the code... but isn't that a lot of repetitive code that could be done in 1 shot?

Share this post


Link to post
Share on other sites

hmmm....autoit3 is must faster than autoit2 :whistle:.... I remember dreading to make my autoit2 script any larger than 500 or so lines because autoit could only process like 20 lines per cycle or per second or something... :P

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