Monday, May 11, 2020

Obj-Open Method in pega

Obj-Open Method:- Obj-Open method is used to retrieve a single record from the clipboard.we have explained below scenario for better understanding of obj-open method.

OBJ-OPEN

In the above screen we have some records in Local Db,Now we are going to fetch single record by using OBJ-OPEN method.

By using page list property we are using all Data class properties into work class
Work class should be look like same as shown in above pictures after using property values of data class in a work class
Create Data transform to perform Retrieve actions and set visibility condition for dynamic layout as if action=='Retrive' then only it is visible.(this is extra work if you want you can do this without data transform).
Create section 
Section's pages and classes tab,add EmpRecord page in Dhan-DhanaNet-Data-Records-EmpRecord class.

Add action Refresh-This section on the button,Add activity and add data transform to set operation as retrieve.
Now we are using obj-open method in above screen shot to fetch required record.
Refer EmpRecord page to a data class in pages and classes tab.

Now it is ready to fetch a required result from the  data base,use flow to run the all our process.
Add flow action in flow
Add section in to flow
Now run the flow and request for the required result
Result has been fetched and displayed on UI.

If you have doubt ask in comments.

No comments:

Post a Comment