I'd recommedn not using Randomize and Rnd. Use a Random object:This glosses over a lot of the detail but basically for each store you generate a random number. If your employees have some ID number that forms an unbroken sequence then you can genereate a random value for that number directly. It's unlikely that that's the case though, so you'd probably generate a random employee index, then get the employee at that index in the table.VB Code:
Dim employeePicker As New Random For Each store In myStores employeeIndex = employeePicker.Next(employeeCount) Next store




Reply With Quote