Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

C# create DataTable

DataTable dt = new DataTable(); 
dt.Clear();
dt.Columns.Add("Name");
dt.Columns.Add("Marks");

DataRow _ravi = dt.NewRow();
_ravi["Name"] = "ravi";
_ravi["Marks"] = "500";
dt.Rows.Add(_ravi);
Comment

C# create DataTable


DataTable dt = new DataTable(); 
dt.Clear();
dt.Columns.Add("Name");
dt.Columns.Add("Marks");
DataRow _ravi = dt.NewRow();
_ravi["Name"] = "ravi";
_ravi["Marks"] = "500";
dt.Rows.Add(_ravi);

Comment

datatable in c#

String[] arr = new String[] { "a", "b" };
            DataTable dt = new DataTable();
            dt.Columns.Add("name");
            dt.Columns.Add("other");
            dt.Rows.Add(arr);

            foreach (DataRow r in dt.Rows)
            {
                Console.WriteLine(r["name"].ToString() + " - " + r["other"].ToString());
            }
Comment

PREVIOUS NEXT
Code Example
Csharp :: how to convert a bitmap to a base64 string c# xamarin universal 
Csharp :: string to uint c# 
Csharp :: set ads for children admob unity 
Csharp :: get current directory cosmos 
Csharp :: public static void Load 
Csharp :: unity google play games plugin spam 
Csharp :: unity keep rotating object 
Csharp :: c# get vector2 distance 
Csharp :: c# how to output in between 0 - 100 in an int array 
Csharp :: how to find avareage of an array in c# 
Csharp :: bower azure repository tag 
Csharp :: how to turn off sprite renderer in unity 
Csharp :: animations for pause menu 
Csharp :: dapper delete where in list 
Csharp :: double tryparse dot comma 
Csharp :: how to generate random letters in C# 
Csharp :: c# close 1 form open another form 
Csharp :: unity detect if animation is playing 
Csharp :: meta keywords tag mvc .net core 
Csharp :: unity how to change the text on a button 
Csharp :: c# display a variable to a text gameobject 
Csharp :: C# int.parse input string wasnt in correct format 
Csharp :: c# console play sound 
Csharp :: regex c# password numbers and letters 
Csharp :: c sharp array to list 
Csharp :: take screenshot in c# 
Csharp :: model in bootsrap 4 
Csharp :: c# float to string with 2 decimals 
Csharp :: c# console background color 
Csharp :: c# loop through files in folder 
ADD CONTENT
Topic
Content
Source link
Name
4+8 =