Help with Vbs?

Discussion in 'Programming' started by Itsreallyrob, Jan 23, 2012.

  1. #1
    I am having trouble learning this language. Some of it I can understand, but there just isn't a good tutorial anywhere! Anyway, I want it to randomly display a name. I am also new to vbs so any tips? And if anyone can help me learn this that would be great. Thanks

    dim max,min
    max = 5
    min = 1
    Randomize
    if x = msgbox(Int(( 5 - 1 + 1 ) * Rnd + 1 ))


    If x = 1 then
    msgbox("name1")
    elseif x = 2 then
    msgbox("name2")
    elseif x = 3 then
    msgbox("name3")
    elseif x = 4 then
    msgbox("name4")
    elseif x = 5 then
    msgbox("name5")
    end if
     
    Itsreallyrob, Jan 23, 2012 IP