Thread: More help

Results 1 to 5 of 5
  1. #1
    zmansquared's Avatar
    Join Date
    Oct 2008
    Gender
    male
    Location
    Kickin it at Microsoft
    Posts
    2,086
    Reputation
    36
    Thanks
    221
    My Mood
    Cheerful

    Exclamation More help

    sorry guys, but what is the code if when button1 is clicked and it randomly picks what to say. say i have 3 difference msgboxes. i only want one to show but i want the program to randomly pick which one to show.

    is that possible?
    Need Help With Coding or Something??? MSN me
    zmansquared@hotmail.com


    I am the one and only Microsoft Fag!!!

    Quote:
    Originally Posted by Arhk
    All games should be hacked, if we don't do it someone else will. Hackers force the progress, of better programming methods.
    ~


    Take this Pic everyone!



    next-

  2. #2
    Lolland's Avatar
    Join Date
    Feb 2009
    Gender
    male
    Location
    Lolland!
    Posts
    3,156
    Reputation
    49
    Thanks
    868
    My Mood
    Inspired
    Dim randomclass as new Random
    Select Case randomclass.next(0,3)
    Case 0: msgbox1
    Case 1: msgbox2
    Case 2: msgbox3

    Something like that

  3. #3
    hopefordope's Avatar
    Join Date
    Aug 2009
    Gender
    male
    Location
    Herndon,VA
    Posts
    264
    Reputation
    9
    Thanks
    86
    My Mood
    Psychedelic
    w8 r u making a spammer???

    Press Thank You[IMG]https://i45.tinypic.com/2hg8w0n.jpghttps://img1.UploadScreensho*****m/images/main/2/3203234450.jpg[/IMG]










    My Releases
    Injector 3G
    Injector 2G
    Injector 1G
    Super Spammer
    CA Cleaner
    My Tutorials
    How to Make a real Injector(PerX)
    How to Make a Calculator(leeched)

  4. #4
    NextGen1's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    Not sure really.
    Posts
    6,312
    Reputation
    382
    Thanks
    3,019
    My Mood
    Amazed
    Code:
     Dim i As Integer
            i = Rnd(1) * 3 + 1
            Select Case i
                Case 1
                    MsgBox("msg1")
                Case 2
                    MsgBox("msg2")
                Case 3
                    MsgBox("msg3")
            End Select
    One more thing to keep in mind when working with VS (Visual Studio) is the term Pseudo Random, What Pseudo Random means (in this case) is you will never get a true random number when using Rnd

    Ex: Every time you start the program you will notice that the series is always the same.

    The work around for that is by calculating a number on your system that is always different (or more different) System Time, Memory Speed , CPU speed, etc.

    That's more of a (good to know) piece of information, and has no real baring here as you only need a small number, but the problem will present itself regardless. I will usually add a label starting at 0 (when in need for a "quick" fix) and have it's number increase by 1 every second and make calculations based off that number to ensure a more random result.
    Last edited by NextGen1; 02-13-2010 at 08:57 PM.


     


     


     



    The Most complete application MPGH will ever offer - 68%




  5. The Following 2 Users Say Thank You to NextGen1 For This Useful Post:

    zmansquared (02-13-2010),Zoom (02-14-2010)

  6. #5
    zmansquared's Avatar
    Join Date
    Oct 2008
    Gender
    male
    Location
    Kickin it at Microsoft
    Posts
    2,086
    Reputation
    36
    Thanks
    221
    My Mood
    Cheerful
    Thanks it works
    Need Help With Coding or Something??? MSN me
    zmansquared@hotmail.com


    I am the one and only Microsoft Fag!!!

    Quote:
    Originally Posted by Arhk
    All games should be hacked, if we don't do it someone else will. Hackers force the progress, of better programming methods.
    ~


    Take this Pic everyone!



    next-

Similar Threads

  1. [Solved] thx but need more help
    By moemoe001 in forum Call of Duty Modern Warfare 2 Help
    Replies: 1
    Last Post: 05-27-2011, 12:32 AM
  2. need some more help.//
    By Osama_Farooq in forum Minecraft Help
    Replies: 3
    Last Post: 04-28-2011, 02:36 AM
  3. [SOLVED] im back xD more help :)
    By Qkill in forum Call of Duty Modern Warfare 2 Help
    Replies: 16
    Last Post: 06-24-2010, 06:22 AM
  4. Even more help (VERY EASY FIX)
    By zmansquared in forum Visual Basic Programming
    Replies: 0
    Last Post: 02-13-2010, 11:24 PM
  5. Need A little more help.
    By BlackRaevyn in forum Suggestions, Requests & General Help
    Replies: 1
    Last Post: 01-06-2009, 09:39 AM