Sign in to follow this  
Followers 0
telmob

How do i get the string?

5 posts in this topic

#1 ·  Posted (edited)

I have 10 strings like this:

$i1h

$i2h

(etc...)

I want to call these strings with random, but i can only get text and not the string itself.

$RandomString = $i&Random(1,10,1)&h
MsgBox(0, "Coin toss", $RandomString)
Edited by telmob

Share this post


Link to post
Share on other sites



assign/put it on array :)

Share this post


Link to post
Share on other sites

#include <Array.au3>

Local $aTest_Array[10] = ['AA', 'BB', 'CC', 'DD', 'EE', 'FF', 'GG', 'HH', 'II', 'JJ']

Msgbox(0,"Info",$aTest_Array[Random(1,10,1)-1])

1 person likes this

Share this post


Link to post
Share on other sites

Thanks man! ;)

Really nice and simple, love it.

Share this post


Link to post
Share on other sites

Thanks man! ;)

Really nice and simple, love it.

Nice, glad can help :)

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