Kick Start


Badge +2

Hi, I am newbie to the K2 products. Firstly I created a smartform using smartobject in K2 studio. The forms already created and I need to know how to connect the form to the Database which all the data entered in that form should store inside the database. Pls help on that.


8 replies

Badge +6

Hi Mani,


 


Firstly, you could generate views from the SmartObject(s) and then add these views to your SmartForm by simply dragging and dropping the view.Alternatively, with the use of rules you could use controls and configure the Datasource to a SmartObject. Either method can be used depending on what you would like to achieve. 


 


SmartObjects created in K2 Studio are deployed to the SmartObject Server and can be accessed from K2 Designer in the respective directory is was deployed to, these SmartObjects can then be used in designing a SmartForm.


 


Regards,

Badge +2

Thanks for the explanation.

 

Is that K2 studio and K2 Designer for Visual Studio provide same function? I take a look on both things, its almost consist same tools. What are the differents with both of these programs? 

Badge +6

K2 Studio and K2 Designer for Visual Studio are the same with the only difference being that K2 Designer for VS allows the user to add custom code, etc.

Userlevel 4
Badge +13

Hi ManiBarathy


 


To store that data entered into a view/form created/generated form a smartobject that was created in K2 Studio.


I suggest trying the following:


1. After creating the SmartObject in K2 Studio


2. Open K2 Designer and expand All Items > Your Projects Name > Right click on Your smartobject that was created in K2 Studio


3. Choose the Generate Views option and select the view type that you want to use.


4. Right click on that view and select generate Form


4. When the view/form is run, data is entered into it and save button is clicked the data will be saved to the smartobject.


 


To store that data entered into a view/form to a smartobject that was created in K2 Studio from which the view/form was not generated from.


I suggest trying the following:


1. You already have you SmartObject and you already have you seperately created View/Form


2. Open the view/form in edit mode


3. Click on the save button and select the rules tab in the properties window on the right hand side.


4. Click Add Rule and configure the rule as follows:


    


     When Save BTN is Clicked


     then on NewK2StudioSmartObject SmartObject, execute its Save method (Configure)


                      - Input mappings (The fields that the user is going to type into the view/form that has to be saved)


                      - Output Mappings (Default)


 


5. Click Finish and Finish


6. When the view/form is run, data is entered into it and save button is clicked the data will be saved to the smartobject.


 


You can test if the data is saved into the smartobject by using the SmartObject - Service Tester Tool located at C:Program Files (x86)K2 blackpearlBinSmartObject Service Tester.exe


 


Kind Regards


Raymond


 

Badge +2

Thanks for the previous post. I am able to insert the data and save it as well. Now please anyone give me idea or clue that how I can integrate the smartform in worklfow as well.

 

Thanks in advance.

 

 

Userlevel 4
Badge +13

Hi ManiBarathy


 


Depending on which program you are using to do the intgartion with, there are three programs to do the integration with where in my opinion the easiest to use is K2 Designer, you then have K2 Studio and K2 Designer for Visual Studio as well.


 


If you have used my previous post's explanation to link the view/form with the smartobject then your project should already be in K2 Designer. Below is how to do the integration from here on...


 


K2 Designer SmartForms Integration


1. After you have created you form, right click on the form and select Design Workflow.


2. Configure the popup wizard (See this link for reference - How workflow integration has been simplified in the K2 Workflow Designer)


3. From here on you can now construct you workflow as you want to and when ever you need to incorporate the view/form the option will be given in the wizard to do this.


Example: When you drag in a User Task into the workflow, Give it a name and click next, there will be a ellipse where you can choose your Form from and then continue with the wizard.


 


K2 Studio & K2 Designer for Visual Studio


Please see this link, explaining how to do smartforms integration using K2 Studion or Visual Studio - SmartForms Integration Wizard

Badge +2

Regards on creating workflow using smartforms, I faced some problems which once I right-clicked and go for design workflow its prompt me this message

 

"

Server Error

To access the K2 Designer the current logged in user needs K2 Server Export rights."
 
What I supposed to do for overcome this issue.
 
TQ
Userlevel 4
Badge +13

Hi ManiBarathy


 


You need to give the user that you are logged in as Export rights.


Please see this PDF Document link on how to give a user permissions- Permissions in K2 - See page 29 in the pdf


 


Kind Regards


Raymond

Reply