Results 1 to 3 of 3

Thread: filelist and listbox order randomization

  1. #1

    Thread Starter
    Member
    Join Date
    Mar 2000
    Location
    Mentor,Oh,US
    Posts
    33

    Unhappy

    Does ANYBODY know how to do this at ALL?????? I am taking selections from filelist and a listbox and adding them to a listbox that will be made invisible and randomized, THEN outputed to a file. Any1 need more specs? Ideas & suggestions would be nice, as well as answers.

    -deadBird

  2. #2
    Guest
    Does this fit your needs?

    Code:
    Function randomnumber(finished)
    Randomize
    randomnumber = Int((Val(finished) * Rnd) + 1)
    End Function
    
    Usage:
    
    Private Sub Command1_Click()
    file1.ListIndex = randomnumber(file1.ListCount)
    Open "MyFile" For Output As #1
    Print #1, file1
    Close #1
    End Sub

  3. #3

    Thread Starter
    Member
    Join Date
    Mar 2000
    Location
    Mentor,Oh,US
    Posts
    33

    Unhappy

    Thats it!? Man I hate you.....

    (well, no not really!)

    I spent a month trying to figure it out. I never made my own functions before. Thankyou VERY MUCH!!!

    -deadBird

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width