Meaning of following line:
DataRow Row = DTTable.Select().Where(x => x.ItemArray[0].ToString() == item.Attributes["name"].Value).FirstOrDefault();
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
VulpesRank #55 · 29.2K reputationPosted Jul 29, 2014, 10:52 AM EDT
Pradeep ShetRank #595 · 4K reputationPosted Jul 29, 2014, 9:31 PM EDT
DataRow Row = DTTable.Select().Where(x => x.ItemArray[0].ToString() == item.Attributes["name"].Value).FirstOrDefault();
The above piece of code says,
-Itterate through the DTTable.Select() which return the array of DataRows
-Apply Where clause saying check the first column within the each item of array and match it with item.Attributes["name"].Value
- If you get any row then return only first row else return default i.e-null
Hope this is what you required. Plz mark it answered if it helped you