Hi md amir,
There is a built in Data Driven feature for WebUI using Excel sheets. Please see the attached screen shots for the first steps in adding a data source in both QA and Dev editions.
describes the feature in the previous version of WebUI, but the portion of video that describes how to data bind a test step to a column in the data source is still valid.
I'm not sure why the code you have for reading/writing from the spreadsheet might not be working, but you can use the built in WebUI data driven feature that will iterate the entire test for each data row.
It would probably be easiest to modifiy or create a new Excel spreadsheet for this type of testing, but if you wanted to to access multple columns, please bind the test step using the syntax: $(ColName1) $(ColName2)...etc
If you wanted to access multiple rows in the data source, please try the following in a code behind file:
"MyCustom Step Description"
DataRow r1 =
String col1 = r1.ItemArray.ToString();
DataRow r2 =
String col2 = r1.ItemArray.ToString();
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking
system and vote to affect the priority of the items.