cancel
Showing results for 
Search instead for 
Did you mean: 

SAP UI5: Unable to draw Gauge on a view other than First view which gets loaded

former_member186390
Participant
0 Kudos
122

Hi,

I referred to a very helpful  blog on SAP UI5 Gauges;

http://scn.sap.com/community/developer-center/front-end/blog/2014/03/07/gauges-in-sapui5

I am able to create gauge refering to the above link in my Split App but the problem is when I am trying to add the gauge to a view other than initial/first view.

Example: My app structure is specified below;

I added code to create Gauge in "Intro" View and view named "CCC"; I have added the same code to View.JS file for both views with a button click navigation is possible from Intro View to CCC View.

The gauges are drawn successfully on Intro View but not in CCC View and I am not able to figure out what is the Problem but I suspect..

      $( document ).ready(function() {

       initialize();   

      });

The above piece of code has role to play in not drawing the gauge on CCC View.

I tried the samething with Shell based app also and the behavior is same. I need help to fix the issue.

Thanks!

View Entire Topic
scott_stefanich
Active Participant
0 Kudos

Hello Amit,

Without having the code, this is a guess, but try creating the gauge in the Controller Lifecycle Hook onAfterRendering.

Regards,

Scott

former_member186390
Participant
0 Kudos

Thanks Scott!