Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
cancel
Showing results for 
Search instead for 
Did you mean: 
nikhil_joy2
Active Contributor

Hi Everyone,

We all might have seen requirements where a timer functionality is required in our dashboards. We can achieve it using SAP provided SDK timer component or by installing real time package. But, it is not so easy always to install add-ins in server side frequently. Especially in organizations which are having BO systems with huge number of users and applications.

We were in a process of recreating one of our SAP Dashboard applications into SAP Design Studio. In our manufacturing environment, this particular SAP Dashboard application was doing a great job by providing real time data with charts and alerts and a data refreshing frequency of 15 minutes. Our BO admin team is not so interested in SDK or add-ins, because of the reasons mentioned already. I was trying an alternative way to achieve this with codes.

How to do it?


Running loops in background is not so good for the performance of dashboard. But here I am running an if..else loop in background with a condition which is our desired time delay in milliseconds.


getTickCount() and if()...else() loop


Two global variables, starttime and endtime are defined to capture time stamps and interval calculates the difference between both in milliseconds.

starttime captures time just after DS_1 load by keeping the code in "On result set changed".

End time is captured inside if() where a dummy variable dummy increments by 1 for each iteration and global variable interval calculates endtime - starttime.

Code inside if() runs until interval reaches the time delay which we have given in the if() condition.

Else()  contains the code to be executed periodically, in my case reloading DS_1.

Please make a note that getTIckCount() function is available from SAP Design studio 1.5 onwards.

Short video below shows the dashboard in action. reloads every 10 seconds based on the above code.

Is this a good solution?

Well, this may not be the best solution as there is calculation involved in every single iteration of loop and loop always runs in background.  But we could achieve our expected timer interval of 15 minutes with this solution without installing SDK or real time package.

P.S

SDK is a powerful option in SAP Design studio, but sometimes it is difficult and time consuming to use SDK components in productive use for each and every requirement, also not all BO admins encourage frequent requests to install add-ins in server side. I believe components like timer,  progress bar etc are basic requirement in a dashboard tool.

Can SAP make these basic components readily available like SAP Dashboard Design ( Xcelsius) to everyone ?

I welcome your feedback, suggestions and alternative ideas on this :smile:

Nikhil Joy

9 Comments
Labels in this area