K2 Smartform Button Event

  • 22 May 2014
  • 1 reply
  • 3 views

Badge +1

I used K2 Smartform create Form.
In my form contain 2 view(view1,view2).
In view1 I have 1 button.
In view2 I have list is autogenerate from smartobject.

How to event button click in view 1 to exceute method get list of smartobject in view2 for binding data in list.

There is one knows,Help me please.

Thank you.


1 reply

Badge +6

Hi Kpsoft,


 


In the first view, add the button then go to the rules tab. Next add a new rule, select the "When a control on a View raises an event" Event. Next select the view where the button is contained. Then select the button control and the rule should look like this "On View1 when the Button is Clicked". 


 


In View2 make sure that it is list view and that the columns or controls have the same properties as the SmartObject. Next select the action "Execute a Smartobject Method", then select the Smartobject you want to populate View 2 with.


 


Then select the "list" method and click the "configure", next click on the output mappings tab and drag the Smartobject properties from the context brower to the controls/columns of View 2 you want to display when the button is clicked. Save and run the form.


 


Let me know if this helps.


 


Kind Regards,


 


Yannick

Reply