![]() | ![]() |
|
09-19-2011 07:24 AM
Hi
I have a requirement in which I have to give a search Form in which the End User will have options to input his own filter criteria, and based on his filter criteria I need to build the WHERE clause and populate the grid with the values fetched from database. Post which he should have an option to select few records and submit the form. The selected records should be updated.
Approach I followed: I created a Business Object with type as Query and the query string is:
EXEC('select a.PSNumber, a.Name from Resources_Data a '+@WhereClause)
In the form I wrote a client script which builds the WHERE clause and pass it to the BO's query parameter, and the Grid gets populated based on the Fetched data. (Followed the approach suggested in http://metastorm.processmapping.com.au/post?Dynami
Now the Challenge is to Select few records from the fetched Data.
I am unable to make the Grid as editable as it is bound to BO of type Query. I can't change the BO type to Table as it has complex and dynamic where condition.
Please help me out in resolving this issue. I am unable to proceed further in this.
Thanks & Regards
Swetha.
09-21-2011 02:20 PM
You sound like your making your life harder than it needs to be ![]()
Editable grids are only read once on form load, so what you are trying to do, does not sound plausible in Metastorm.
Instead you can keep what you have and then create the fields and an Add, Edit and Delete button below your grid. Show the add if no rows are selected or show Edit or Delete if a row is. When Add is clicked you then can show data entry fields below and encode the Save to insert into the DB. With the Edit you would show the same fields but populate with your selected row.
All the buttons would be coded to handle the updates. Just set the data business object to always refresh and the rest should be rather straigtht forward.
04-06-2012 06:05 PM
![]() |
![]() |
![]() |
|
|
![]() |
![]() |
![]() |
















