Freigeben über


EWA Web Part Error

As this year comes to a close, I figured why wait until the New Year to do to write my first blog post. So here goes...

Today I am writing about an issue that I encountered while troubleshooting an Excel Web Access Web Part issue. What appears to be a complex issue, ended up having a simple solution. I have to thank my colleague and fellow Premier Field Engineer, John Scott, for his development expertise to help me figure this one out.

For the setup, SharePoint had a Secure Store account that was accessing data from a SSAS (SQL Server Analysis Services) Cube using the EWA web part. On the page, we had a Content Editor web part that linked to a file with some JavaScript. It displays a Do Filter link on the page that passes the parameter "Canada" to the slicer in the Excel Workbook that is presented in the EWA web part.

 
<a href="javascript:" onclick="DoFilter();">Do Filter</a>
<script type='text/javascript'>
function DoFilter() {
    var objCollection = {};
    var ewa = Ewa.EwaControl.getInstances().getItem(0);
    objCollection['Slicer_Customer_Geography'] = ['Canada'];
    ewa.getActiveWorkbook().setParametersAsync(objCollection, SetParamsAsyncCallback, null);
}
function SetParamsAsyncCallback(asyncResult)
{
    if (asyncResult.getDescription() != null) {
    alert(asyncResult.getDescription());
    }
}
</script>

dofilter

The problem surfaced when clicking on the Do Filter link, which resulted in being greeted with the error message:

We're sorry. Because of how Excel Services Application is configured, we can't complete what you asked us to do. ewa-error

What could this be?

After validating the configuration of Excel Services in Central Administration, checking that the Secure Store account had the proper permissions to the back-end data source, it didn't look like there was anything wrong.

I then confirmed that the parameters were available in the Excel workbook. If you are following along, you can add it by (1) viewing the Info on the workbook, (2) open the Browser View Options, if not already present, (3) Add the parameter, (4) select the Slicer, (5) and click OK.

excelworkbooksettings

Next, I compared the EWA web part configuration and compared it to an environment that works. I found that the difference was with the Parameter Modification checkbox. Could this be it? really?

webpartconfig

After enabling it, then saving/publishing the page; clicking the Do Filter link now worked!

dofilterworking

Thanks for reading!

Joe

Did you find this post helpful? I would like to hear about it.