Horje
how to generate random unique id in c# Code Example
how to generate random unique id in c#
public Random a = new Random(); // replace from new Random(DateTime.Now.Ticks.GetHashCode());
                                // Since similar code is done in default constructor internally
public List<int> randomList = new List<int>();
int MyNumber = 0;
private void NewNumber()
{
  	MyNumber = a.Next(0, 10);
  	while(randomList.Contains(MyNumber))
    	MyNumber = a.Next(0, 10);
}




Csharp

Related
c# get type of class Code Example c# get type of class Code Example
how to print something in c# Code Example how to print something in c# Code Example
c# web api return image file Code Example c# web api return image file Code Example
HOW TO RETURN CELL VALUE FROM EXCEL IN C# Code Example HOW TO RETURN CELL VALUE FROM EXCEL IN C# Code Example
dictionary to list c# Code Example dictionary to list c# Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
10