no doubt it works in simplicity.. but the datatable is going to grow larger.. I would prefer first option of going to for loop.. Thanks
--- On Mon, 10/12/09, saurabh gupta <[email protected]> wrote: From: saurabh gupta <[email protected]> Subject: Re: Checkbox parameterization To: [email protected] Date: Monday, October 12, 2009, 7:15 AM Hi All, I believe we could have much easier option without taking the risk of descriptive programing and comlexisy of FOR loop. I would prefer you to parameterise the required property of check box in OR and make an reusable action and run on all rows, inserting the value of the property in local data sheet. Will look like some thing as below. .WebCheckBox("CheckBox").Set "ON" and in datasheet. admin adminNA adminXY adminAB etc.... Please let me know if its better. On Sat, Oct 10, 2009 at 12:56 AM, Kiran Ogeti <[email protected]> wrote: thanks Sridhar.. you are awesome --- On Fri, 10/9/09, Sreedhar Mallipeddi <[email protected]> wrote: From: Sreedhar Mallipeddi <[email protected]> Subject: Re: Checkbox parameterization To: [email protected] Date: Friday, October 9, 2009, 2:06 AM u have to use like this.... .WebCheckBox("value:="&Role).Set "ON" On Thu, Oct 8, 2009 at 4:01 PM, Kiran Ogeti <[email protected]> wrote: Thanks Sridhar.. this is what I did per ur instructions: Pl see in bold & red and advice how to assing element of array to property Value RolesForAll = datatable.Value("SetofRoles",1) ## Read values from data table## RolesForEach = split(RolesForAll,",",-1) ##Split them and Put them in array## For each Role in RolesForEach .WebCheckBox("value:=Role").Set "ON" Next --- On Thu, 10/8/09, Sreedhar Mallipeddi <[email protected]> wrote: From: Sreedhar Mallipeddi <[email protected]> Subject: Re: Checkbox parameterization To: [email protected] Date: Thursday, October 8, 2009, 6:53 PM Take all the checkbox value property in to a single cell in datatable seperated by ":" in ur script split them in to a array Write a loop and call each value and set it on. On Thu, Oct 8, 2009 at 11:22 AM, Kiran Ogeti <[email protected]> wrote: Hi all, I have 10 Checkboxes on a page .. they work fine by explicitly mentioned each one with value.. now how to parameterize them by datatable...so it will be a single line .WebCheckBox("value:=admin").Set "ON" ( 1st checkbox) .WebCheckBox("value:=adminNA").Set "ON" (2 nd check box) .WebCheckBox("value:=adminAU").Set "ON" (3rd check box) Thanks How to handle checkboxes using parameterization using datatable -- Mallipeddi Sreedhar 91-9000994721 -- Mallipeddi Sreedhar 91-9000994721 -- BR. Saurabh Gupta Mob. +91-9663304288 ------------------- I have not failed, I've just found 10000 ways that won't work. Thomas A. Edison --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google "QTP - HP Quick Test Professional - Automated Software Testing" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/MercuryQTP?hl=en -~----------~----~----~----~------~----~------~--~---
