Page 1 of 1

Running mutliple Row

Posted: Fri Apr 26, 2013 4:25 pm
by omayer
I do have simpledata table with 10 rows and 2 columns, one column called 'activity' , how do I run below step 2 using data from all 10 rows, w/out splitting the testcase with another .cs file

i do only need to run step2 for 10 times,

Thank you in Advance

Code: Select all

 void ITestModule.Run()
        {
        		
            Mouse.DefaultMoveTime = 300;
            Keyboard.DefaultKeyPressTime = 100;
            Delay.SpeedFactor = 1.0;

            	//Main Page
          		WebDocument webdoc ="/dom[@page='test.cfm']";
          		webdoc.EnsureVisible();

             	//step 1. Choose an existing orderID
           		GenericStaticClass.ClickOnSelectTag(webdoc.FindSingle(".//form[@name='Can']//select[@id='qs']",30000),"Can","CanID");
		
		
		//step 2. Add All activities 
   		
				
		     canPrPage.SelectActivityOne(activity); 

        }
        		
    }
}

Re: Running mutliple Row

Posted: Fri Apr 26, 2013 8:44 pm
by Ciege
Add all the data from the 10 rows to an list, then add a foreach loop that loops the list and does your SelectActivityOne...