Jump to content

print a random value

Recommended Posts

Dear readers,

Mij code is as displayed here:

$msgrand = 1

$text0 = "....."
$text1 = "....."
$text2 = "....."
$text3 = "....."

Now I do this:

if $msgrand >= 1 Then
    $nr = Random(0, 9)

The problem is, that it wont send the chosen text. Can someone tell me what I am doing wrong?

I want to display (send) one of the random text that has been set with $text0 up to $text3.

Best regards

P.S. the ;WHAT HERE? part should need a code, but I dont know the correct one!

something like Send($text[$nr]) maybe?

Edited by Valkyrie
Link to comment
Share on other sites

I cant use

local $text = ["world domination!?", "level?", "boooooorrrringgg!"]

gives me the error:

C:\Users\Angelo\Desktop\sknnr.au3(4,9) : ERROR: syntax error

which points to:

local $text = ["world domination!?", "level?", "boooooorrrringgg!"]
Look at my code again. Notice that I specified how many items I was adding.

Broken link? PM me and I'll send you the file!

Link to comment
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

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...