Add WebParts on tabs/accordion

rss

Posted by Katerina - May 12 ’14 at 08:16

Hi Dimitry,

 

Is it possible to add web parts under the froms tabs and accordion? And if yes how?

 

 

Thanks

  • Dmitry Kozlov
    Dmitry Kozlov
    Admin
    Member for: 5 years 10 months 26 days
    #1 by Dmitry Kozlov May 13 ’14 at 03:40

    You can add a web part under the form and then replace it with JavaScript. Get more info:

    http://forum.spform.com/forms-designer-for-sharepoint-20/excel-web-access-web-part-22147/

  • Katerina
    Member
    Member for: 5 years 3 months 20 days
    #2 by Katerina May 16 ’14 at 09:06

    Hi Dimitry,

     

    I have tried this but it doesn't add te web part under the form tab, It doesn't show anything.

    Any Ideas?

  • Dmitry Kozlov
    Dmitry Kozlov
    Admin
    Member for: 5 years 10 months 26 days
    #3 by Dmitry Kozlov May 18 ’14 at 05:34

    [#2]: Did you add the web part onto the form page? Does it appear under the form?

  • Katerina
    Member
    Member for: 5 years 3 months 20 days
    #4 by Katerina May 19 ’14 at 03:17

    Yes I did and it appears on the bottom of the form.

  • Dmitry Kozlov
    Dmitry Kozlov
    Admin
    Member for: 5 years 10 months 26 days
    #5 by Dmitry Kozlov May 20 ’14 at 02:34

    [#4]: Please, put HTML-control into a tab where you wish to append the web part. Put the following code into its Content property:

    <div id="wpPlaceHolder"></div>
    

    Next, open JS-editor and put the following code there:

    $('td[id^="MSOZoneCell_WebPartWPQ"]:eq(1) > table')
      .detach()
      .appendTo('#wpPlaceHolder');
    

    Replace the highlighted number with the order number of the web part on the form page.

  • Katerina
    Member
    Member for: 5 years 3 months 20 days
    #6 by Katerina May 20 ’14 at 02:51

    Hi Dimitry,

     

    What do you mean by Replace the highlighted number with the order number of the web part on the form page.

    Wheere can I find that?

     

    Thanks

  • Dmitry Kozlov
    Dmitry Kozlov
    Admin
    Member for: 5 years 10 months 26 days
    #7 by Dmitry Kozlov May 20 ’14 at 03:49

    [#6]: I've highlighted it in my code, here: td[id^="MSOZoneCell_WebPartWPQ"]:eq(1)

  • Katerina
    Member
    Member for: 5 years 3 months 20 days
    #8 by Katerina May 20 ’14 at 03:53

    I mean where can I find that number? I have seen it in your code, but where can I find it to put it there?

  • Dmitry Kozlov
    Dmitry Kozlov
    Admin
    Member for: 5 years 10 months 26 days
    #9 by Dmitry Kozlov May 20 ’14 at 03:55

    [#8]: it's just an order number of the web part on the page: 0,1,2...

  • Katerina
    Member
    Member for: 5 years 3 months 20 days
    #10 by Katerina May 22 ’14 at 06:46

    Again is not doing what it should. Instead I found out that  if I put eq(0) it replace the entire form with my web part. If I put 1 or any other number it just leave the web part on the bottom of the page.

     

    Any ideas?

     

    Thanks

Displaying 1 to 10 of 18 messages
Previous12