Results 1 to 3 of 3

Thread: Picture Question

Hybrid View

  1. #1
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606
    try this instead

    VB Code:
    1. Public Function Rand(ByVal Low As Long, ByVal high As Long) As Long
    2. Rand = Int((high - Low + 1) * Rnd) + Low
    3. End Function
    4.  
    5. Sub opponent()
    6. Dim computer(1 To 3) As String
    7. computer(1) = App.Path & "\carl.bmp"
    8. computer(2) = App.Path & "\antonio.bmp"
    9. computer(3) = App.Path & "\thomas.bmp"
    10. piccpu.picture = LoadPicture(computer(Rand(1, 3)))
    11. End Sub
    12.  
    13. Private Sub Form_Load()
    14. opponent
    15. End Sub
    Last edited by sebs; Apr 16th, 2002 at 10:35 AM.

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