Sign in to follow this  
Followers 0
tttommeke

_RandomString()

1 post in this topic

Creates a random string with numbers, low and high chars. Good for when you need a random name for a variable,file,...

$StringArray = StringSplit("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789","")
Func _Randomstring($Lenght)
$String = ""
$I = 0
Do
$String = $String & $StringArray[Random(1,$Stringarray[0])]
$I += 1
Until $I = $Lenght
Return $String
EndFunc

Call it like :

_Randomstring(5)

To get a string from 5 characts

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