Excel web access web part

Discussions about Forms Designer for SharePoint 2013 / 2016 and Office 365.
Locked
holtonba
Posts: 7
Joined: Sun Feb 23, 2014

23 Feb 2014

Is there any way to put the result of an Excel web access web part inside of a Tab of SP Forms? We have a form that uses tabs. Inside one of the tabs is a related item list that is a document library containing excel files. We are able to select one of these files and use the web part connection to send the document (excel file) URL to an Excel web access web part that is below the SP Form web part. However, this isn't very intuitive to users (they need to scroll down to see the Excel contents). It would be much better if the excel file displayed inside the tab.

User avatar
Dmitry Kozlov
Site Admin
Posts: 1524
Joined: Thu Jun 07, 2012

24 Feb 2014

You can replace the Excel web access web part with help of JavaScript. Please, open Forms Designer and put HTML-control into the form where you wish to display Excel web access. Place the following DIV-container into its Content property:

Code: Select all

<div id="excelPlaceHolder"></div>
Now, open JS-editor of Forms Designer and put the following code there:

Code: Select all

$('div[id^="MSOZoneCell_WebPartWPQ"]').eq(2).detach().appendTo('#excelPlaceHolder');
Please, note that I have highlighted the eq function. You should pass the order number of Excel Web access on the form page into this function.

holtonba
Posts: 7
Joined: Sun Feb 23, 2014

25 Feb 2014

Seems to work well, thanks! Editing the normal page behaves a little strange after doing this, but we can work around that.

Also, in this same scenario, when clicking on the Selection icon for any of the document library items, there is a postback and our tab focus is lost - so we have to re-navigate to the correct tab. The selected Excel file is displayed jus fine, but the viewstate is lost when selecting an item. Any clever fixes for that?


thanks

Locked
  • Information
  • Who is online

    Users browsing this forum: No registered users and 17 guests