Add WebParts on tabs/accordion
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 KozlovAdminMember for: 9 years 8 months 7 days
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/
-
KaterinaMemberMember for: 9 years 29 days
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 KozlovAdminMember for: 9 years 8 months 7 days
[#2]: Did you add the web part onto the form page? Does it appear under the form?
-
KaterinaMemberMember for: 9 years 29 days
Yes I did and it appears on the bottom of the form.
-
Dmitry KozlovAdminMember for: 9 years 8 months 7 days
[#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.
-
KaterinaMemberMember for: 9 years 29 days
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 KozlovAdminMember for: 9 years 8 months 7 days
[#6]: I've highlighted it in my code, here: td[id^="MSOZoneCell_WebPartWPQ"]:eq(1)
-
KaterinaMemberMember for: 9 years 29 days
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 KozlovAdminMember for: 9 years 8 months 7 days
[#8]: it's just an order number of the web part on the page: 0,1,2...
-
KaterinaMemberMember for: 9 years 29 days
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