Results 1 to 2 of 2

Thread: Adding random numbers to a field

  1. #1

    Thread Starter
    Guru Clunietp's Avatar
    Join Date
    Oct 1999
    Location
    USA
    Posts
    1,844

    Post

    code for random, 1 - 2 digit whole numbers:
    Code:
        Dim tmp As Long
        
        Randomize
        
        tmp = Rnd() * 100
        
        Debug.Print tmp
    just take tmp, and add it to a field in a current recordset (RS)

    rs.fields("MyField").value = rs.fields("MyField").value & tmp


    HTH

    Tom

  2. #2
    New Member
    Join Date
    Jan 2000
    Posts
    1

    Post

    Is it possible to add a random number to the end of a field? If so what is the easiest way?

    John

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