Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
3
Reply
data table to dictionary
Dinesh Santhalingam
Dec 23 2016 5:25 AM
228
I have a data table .i want to load my entire data table to my dictionary without reading each row every time.suggest me some ideas?
data table dt=new data table();
//I have some data in my table
Dictionary
<
string
, object
>
lst
=
new
Dictionary
<
string
, object
>
();
try
{
lst.Add(row["Time"].ToString(), row["Inuse"] as string);
}
catch (Exception ex)
{
throw ex;
}
return lst;
I tried this.But i want to load data table without using foreach loop .
Reply
Upload Source Code
Select only zip and rar file.
Post
Reset
Answers (
3
)
How can I Decryption This HashSha256 algorithm?
list object if contain one value then return another one c#