c# - Problem figuring out how if I am on the first row and column of a datatable? -


.net 2.0 trying find if on first row can comparison

foreach(datarow row in tbl.rows) {     if (row<something> == "first row") { continue; }      foreach(datacolumn col in tbl.columns) {         if (something == "first column) { continue; }  .... 

but escaping me.

quick 'n' dirty says can throw int counter in there.

int rowcounter=0; foreach(datarow row in tbl.rows)  {       rowcounter++;     if (rowcounter==1) { continue; }     ...      //do same columncounter first-column first-row } 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -