This project has moved. For the latest updates, please go here.

passing with for on html controls

Topics: Developer Forum
May 7, 2013 at 2:18 PM
someone suggested me to try HtmlAgility Pack for I want to do.
I have several html controls that their's ID run from 1 to 10, like "txtName_1", "txtName_2" ,
and so on until "txtName_3".
I do not want to make for every control code to take it value, I want to make some kind of for that run from 1 to 10 and add only the number for the control, something like:
for (int i = 1; i <= 10; i++)
name = (txtName_ + ind).value;
I make something on JavaScript and it works good, the question is how I can make it on and C#.
Now I have line of code to every control and it is lot of code.

Can I use the Html Agility Pack for this and how do it do it?