Hi,
I have a datatable with 4 columns and 3 rows. How may I get directly 2.nd column and 3.th row's value?
Regards.
Getting a cell's value in datatable
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.
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
Blocked AccountRank #403 · 6.2K reputationPosted Jun 20, 2012, 11:46 PM EDT
you can get 2nd column and 3rd rows value directly by using this code
string va = datatable.Rows[2][1].ToString();