For a project I have currently done, I have designed a database that contains a table, which contains the field "NHS Number". People in the UK would know that this is a unique ten digit number.

I am in the process of adding "people" into the database for testing purposes.

In real life, different people would have totally different NHS Numbers, so using AutoNumber is totally out of the question. So I have to have a random number...

I have currently made a random integer generator to solve this problem... or so I thought

Using the following code:
vb Code:
  1. Private Sub Command1_Click()
  2.     Dim dblRand As Double
  3.     Dim strRand As String
  4.     dblRand = Int(Rnd * 10000000000#)
  5.     Text1.Text = dblRand
  6.     Clipboard.Clear
  7.     strRand = dblRand
  8.     Clipboard.SetText strRand
  9. End Sub

Using the
Code:
Int()
command doesn't acutally generate a random number each time for me. While I'm running the program, it generates random numbers, fair enough. When I start the program again, it generates the same random numbers it did before

Is there something I've done wrong? Is there another way to randomise numbers?

Thanks