Grid:how to search and return for single row where two columns are compared from multiple records
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Grid:how to search and return for single row where two columns are compared from multiple records
any suggestions
:In a Grid using Java script how to search and return return the row from Grid where two columns are compared from multiple records.
compare both columns to avoid duplicate value from one of the rows.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Columns= new Array ("param1","param2");
Values=new Array("SUB","TEST");
RowIndex = Grid2.FindRowByMultipleValues("Columns", "Values");
not working as findrowbymultiplevalues method gives an error. FindRowByMultipleValues("Columns", "Values");object not found.
any ideas.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Could you try this... RowIndex = Grid2.FindRowByMultipleValues(Columns, Values);
Double Quotes should be the issue here - [Grid2.FindRowByMultipleValues("Columns", "Values");]
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
RowIndex = Grid2.FindRowByMultipleValues(Columns, Values);
i changed the 2nd lin too :
Values=new Array(COUNTRY,asa);
instead Values=new Array("COUNTRY","asa");
i tried this , still gives an error Unable to find the object FindRowByMultipleValues(null, null).
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No, while declaring the variables, the values should be within the quotes...
Columns= new Array ("param1","param2");
Values=new Array("SUB","TEST");
But while finding, if you are using a variable name, avoid using the quotes...
RowIndex = Grid2.FindRowByMultipleValues(Columns, Values);
TestComplete manual has vast examples... the below is for Find method.
You can also refer w3school for JavaScript help...
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks.. If I declare values in quotes, i get java run time error "sub" is not defined.
I went through find methods and used the find row method. it works good. but currently i need to search the records that matches more than one columns in a a row.
So was using this method:FindRowByMultipleValues .
I will check in w3 schools. Thanks alot for responding.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
any other suggestions would be appreciated.
for searching row giving two or more than two column values.
