Micro Focus QTP (UFT) Forums

Full Version: Skip a cell while QTP is reading datatable
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi all,

I have a generic script who check value or statut field.
For example, I have 2 columns in my datatable :
In the Test 1 : I call check_generic_script and I check the 2 fields
In the Test 2 : I call check_generic_script and I check only 1 field
So I want kept the same generic script for the two tests : How I can ignore the second column? Is there a data to put into the datatable to ignore the reading?
Sorry for my poor English, I hope you understand me.
Thanks
Mikee
I can think of two ways off the head...

1) create a flag for each column. say having values Y and N. So if both columns are Y. Run both. If only 1) is Y run 1)

2) you can have the check for blank value in a cell..if a cell is blank than create a logic which takes your script to skip that part of the code while execution..

Hope this helps
Thanks for your answer !!
Mikee