SharePoint 2013 Multiple KPI Web Parts in one page

The following script solves the problem with endless loading the KPI web parts.
Add a script editor web part on the bottom of the page and paste the script.


function updateStatusLists() {
  $("div[id*='upPanel']").each(function(index){
     if(index >= 1){
      var udpId = this.id;
      var pbId = udpId.replace("__upPanel", "$KpiPostBackEventHandler");
      __doPostBack(pbId,'UpdateId=1');	
    }		
  });
}
$(document).ready(function(){
  $("div[id*='kpiimagediv'] img").each(function(item){
    if(this.src =="http://MySharepointURL/_layouts/15/images/kpiprogressbar.GIF"){
     updateStatusLists();
     return;
    }
  });
});
Advertisements
This entry was posted in SharePoint 2013. Bookmark the permalink.

7 Responses to SharePoint 2013 Multiple KPI Web Parts in one page

  1. Kukdai says:

    it doesn’t work i replaced this https://spark.ferranti.be with my url still not working

  2. Paran says:

    its not working for us. Please advise, I still see the loading gif file for the second kpi webpart

    • Enable “”Display edit toolbar in view mode for the webpart. Check if Actions > Update Values is working. Open developer tools and see via DOM Explorer why doesn’t work. You have to invoke the Update Values.

    • in the source you have to find something like:
      <ie:menuitem id="ctl00_ctl43_g_403855b6_0522_476a_9261_028f3e9f3cf2_KpiIconDefault" type="option" iconSrc="/_layouts/15/images/KPIDefault-0.GIF" onMenuClick="__doPostBack(&#39;ctl00$ctl43$g_403855b6_0522_476a_9261_028f3e9f3cf2$KpiPostBackEventHandler&#39;,&#39;Icon=KpiIconDefault&#39;)" text="Default" menuGroupId="2147483647"></ie:menuitem>

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s