Posted on: 9/16/2015 9:27:14 AM | Views : 842

Hi all,
I want to create unique id in c# application . so I found from google following code.
public string Get10Digits() { var bytes = new byte[10]; var rng = RandomNumberGenerator.Create(); rng.GetBytes(bytes); uint random = BitConverter.ToUInt32(bytes, 0) % 100000000; return String.Format("{0:D10}", random); } Please tell me there is any scenario after long time it can produce duplicate no . ?
If yes then please suggest me any other idea Rather than GUID . provide me any custom code which never be produce duplicate no.
Thanks

Go to the complete details ...