Is it possible to show multiple infopath forms in a webpart with tabbed approach for each form

คำตอบ Is it possible to show multiple infopath forms in a webpart with tabbed approach for each form

  • 02 Mei 2012 19:28
     
     

    Hi ,

              Is it possible to show multiple infopath forms in a single webpart with top navigation where each tab refers to each form  and each form have save and submit buttons save doesnt do any validations while submit do validations . The submit button on form1 locks it and make it read only so the admin can view and set status of the document. Also want to have admin section for each form not visible to user and is editable for admin and based on admin decision other tabs enabled or disabled


    jagirs

Semua Balasan

  • 02 Mei 2012 22:21
     
     

    1. Using multiple Views with tab navigation in single InfoPath form with a single web part

    In your scenario, you may try to split a long/complex form into different views with Back and Next navigation button so that users can move around different views.  You can also add a condition rule to disable navigation button based on login user.

    2. Using multiple InfoPath form template with multiple web part with easy tab script

    You can create different InfoPath forms and show it through different web parts. Use Easy-tab (http://usermanagedsolutions.com/SharePoint-User-Toolkit/Pages/Easy-Tabs-v5.aspx) to auto generate tab UI.

    I recommend first approach, so you only need to maintain one single InfoPath form template.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com





  • 03 Mei 2012 10:54
     
     

    If u noticed i asked for making portion of view read only and portion of view editable based on login credentials.(if i am logged in as user and clicked on submit section then the values entered inside the form will be made read only for user while there is another section in form which need to be editable for admin (only visible this section for admin)


    jagirs

  • 03 Mei 2012 16:59
     
     

    You should say section or view instead of forms. You also mentioned InfoPath form viewer web part, it made me a little confuse. That’s why I recommend you to create a multiple views and disable navigation button based on current login user.

    What you saying is possible. InfoPath form provides useful functions such as UserName(). UserName() function returns current login user. All you need to do is compare current login user and administrator. You should have a hidden data field where you store administrator account.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com





  • 04 Mei 2012 3:24
     
     

    Sanga,

                       MY basic idea is to create tabs for each form placing in a webpart and then readonly for  portion of form.

    Say for example if i have a form with user section having some controls and bottom  of the form having admin section having certain controls along with submit separately for user and admin sections. This admin section is editable for admins and more over i need to get workflow history into admin sections.when user submits the form his portion becomes read only and when admin logged in his portion is editable but user portion is still read only


    jagirs

  • 04 Mei 2012 5:42
     
     

    Jagirs,

    I'm still not sure about "tabs for each form placing in a webpart". Are you trying to say creating a single form with tabs (basically buttons), so people can switch to different views?. If my understanding is correct, then yes it is possible.

    Setting controls as editable/read-only based on loggin user is possible in InfoPath. Only thing you need is to provide who is admin so that InfoPath can compare current login user and admin to set controls as editable or not.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com


  • 04 Mei 2012 11:32
     
     

    Sangha,

                             Intially I created tabbed infopath form with multiple views.So inside infopath form when you click on tab it switches to new view.

    Now in each view i have 2 different sections section one contains some of the controls along with submit and save button specific to that section.

    In the second section of the view i have again 3 tabs and here each tab represent 1 section so when u click on each tab the section changes and this bottom section belongs to admin. In admin section tab 1 contains the actions (i.e approve or reject), tab  2 contains work flow history , tab 3 for comments.

    so when user comes to default view of the form he enters the information in section1 above the admin section and click on submit button.then his information is locked (i e his section becomes read only) and send notification to admin who is specific to that view ( here each view have separate admins). then admin logs in and see the user information which is still read only mode but bottom part of the section is admin which is editable he takes necessary task action and click on submit button of admin section.Then it again goes notification to user .If admin approves this view then next tab of user section becomes active.Also as i mentioned earlier the other two tabs are workflow history and comments need to be captured this actions and comments entered by admin.

     


    jagirs

  • 04 Mei 2012 16:38
     
     Jawab

    Jagirs,

    Thanks for your full description. I read all of your previous posts again. I thought you are asking how to create a tab and how to make field as read-only based on login user.

    Original question was “Is it possible to show multiple infopath forms in a single webpart with top navigation where each tab refers to each form and each form have save and submit buttons save doesnt do any validations while submit do validations”

    Yes, it is possible. I think you already have a good sense for showing multiple views with tap navigation. Validation for submit button only is also possible. Create one hidden Boolean field for validation. Use this field when you create a validation rule. Let’s assume you have a field named “Address” and hidden field named “ValidationCheck”. Set your validation rule as follow example. Do validation only if “Address” is empty and “ValidationCheck” is true.

    You can add an action rule to set “ValidationCheck” value as true or false on save/submit buttons. Or you can make a control (radio button, dropdown), so user can select save/submit before submit the form.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com

  • 04 Mei 2012 17:30
     
     

    Sangha,

                        So i believe you got some understanding to my application what i am trying  to build. So let us consider view1 .View 1 have 2 sections with top section having some of the controls embedded in it.Bottom section (Admin Section)contain 3 more sections inside this section. 

    So user section contains save and submit button. Admin section contains submit button as well. when user clicks on submit button his section is turned to read only but bottom admin section is still editable.

    So my goal is to make only portion of view read only (top section read only ) and bottom section can be editable.


    jagirs

  • 04 Mei 2012 18:17
     
     

    Jagirs,

    I think the confusion comes from between sections and controls. You have to create a rule to each control to make it as read-only or editable. You can user UserName() function to find out current login user is admin or general user.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com

  • 04 Mei 2012 18:35
     
     Jawab

    I am already checking that condition to see if current login user is admin or general user (with the help of user profile webservice i am able to get logged in user information and comparing this user with sharepoint custom list i created which stores username and permission levels columns).

    So if i understand correctly u are saying to put condition to each and every control and validate if it is user or admin.(If that is the case being mine a complex form it may have performance issue later).

    I have gone through these below articles and make a work around.

    http://www.bizsupportonline.net/blog/2009/03/switch-read-only-view-submit-infopath/

    http://office.microsoft.com/en-us/infopath-help/design-a-read-only-view-HA010211228.aspx

         This works fine if i want to make entire view as readonly but fails if i want to make portion of view as read only. So can u give me solution which is best way to do it.

    If validation on each control is only way then i have to make lot of conditions for every view in my form .

    Paul galvin suggested one solution i e

    http://paulgalvinsoldblog.wordpress.com/2008/04/25/quick-and-simple-make-an-infopath-form-read-only-infopath-forms-services-in-moss/ 

    i am not sure this works for my scenario

    jagirs


    • Diedit oleh SPDEV2010 04 Mei 2012 18:46 modify
    • Ditandai sebagai Jawaban oleh SPDEV2010 13 Mei 2012 12:54
    •  
  • 04 Mei 2012 19:50
     
     

    Jagirs,

    Your understanding is correct, and I'm afraid to say there is no workaround. You can make entire view as a read-only, but it is not possible to make a portion of view as a read-only. You have to add a rule to each control.

    I still remember my InfoPth project in 2007. I spent 1 1/2 hours to add rules to each control in InfoPath 2007. As you know you can copy and past rules in InfoPath 2010, so it will save you lots time.

    Hope it helps


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com


  • 07 Mei 2012 15:35
     
     

    Sangha,

                      Do you think splitting admin section user section seprately as different webparts can acheive this functionality what i am lookin for may be xml form view webpart ?


    jagirs

  • 07 Mei 2012 19:27
     
     

    I don’t know the detail of your requirements, and I don’t think XML form viewer can be configured to display different multiple views on same SharePoint page.

    What I can tell you is that you can set up the rule to display a different view (user & admin) when the form is opened. You can also add a button to switch views while the form is still opened. If you split user and admin section to separated views, then the entire view can be marked as a read-only which might help you for saving a few hours.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com

  • 07 Mei 2012 20:27
     
     

    Sangha,

                      The user needs to fill the infopath form.There are multiple phases so i created multiple views in in same form in tabbed approach where each tab represent 1 view (ior i can say phase).User can switch from one tab to another by clicking on the tabs and if the conditions or rules are met.

    USer come and see view1 in tab manner where tab1 contains view 1 . View1 contains 2 sections top section is user section contains different controls and sections. Bottom view is admin view can be accessable only by admins. User Section have save and submit buttons while admin have just submit button.When the user clicks on the save button it saves to forms library and if user clicks on submit button it makes the view read only and the other tabs are still inactive until admin take necessary approval action (i e btton section acessable by admin where takes actions).Say for example when admin sees the read only user section and if he take approve action in the bottom of the section then the next tab becomes active for the user.This is the process for every view.

    Also in Admin action again i created three tabs which each tab represent separate sections. Section 1 is workflow action tab either approval/Reject/Pending while Tab2 captures workflow history and tab 3 captures comments where admin and user bounces over each other.

    As i mentioned earlier the Admin section is not accessable by the user in the sense the work flow action tab (i e approval/reject/..) cannot be seen by user but they can see workflow history tab and comments tab where user can also put comments

    Can you give me best pratice to achieve my goal. I have also created seperate forms and also different views in single form. which ever approach is better pratice that helps me a lot.


    jagirs

  • 07 Mei 2012 23:40
     
     
    1. Using a single View with two different sections for admin & user
    2. Using multiple Views for admin & user

    It’s up to your form design requirement or your preference. Both approaches have been used in SharePoint projects in variety industries.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com


  • 08 Mei 2012 13:00
     
     

    Sanga,

                    Can we pull the values of the existing form into new view view in textual format with showing only the answers selected by user .


    jagirs

  • 08 Mei 2012 16:45
     
     

    InfoPath View simply offers user to have a different ways to look at the same data. No matter how many views you have, no matter what View users submit, they are all the same data. You can show existing value(same data) from different view into a new view. If you meant to say to show values in different form (.XML) into a view of a new form, then you can do it only if the value is promoted as a column in InfoPath form library.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com


  • 08 Mei 2012 17:49
     
     

    Sanga

    I mentioned you without using read only form or writing conditions to each and every control in the form can you show the user submitted values section in new view as read only and bottom section i e admin as editable


    jagirs

  • 08 Mei 2012 20:37
     
     Jawab

    Jagirs,

    No, you can not make a field as a read-only without writing conditions/using read-only form. You HAVE to use read-only for entire view or add condition to each control. You might contact Micorosoft Support to check other available options that I have not known.


    백상하 - Stop hacking my blog http://blog.naver.com/agilepoint
    쉐어포인트 배움터 http://sharepointkorea.com