We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Adding data to 'e-resource' dynamically

Hi all,

While I'm receiving data from an API, I need to populate the array associated to my e-resource at my schedule, but it only works if I do it before this component is mounted. I need to call the method "loadData()" inside "ngOnInit" and dynamically, according to user requests... There are screenshots of my code (html and ts)

After this functions ends, both arrays are filled properly, but the data is not displaying on the schedule.
Any ideas?

3 Replies

HB Hareesh Balasubramanian Syncfusion Team July 25, 2019 11:48 AM

Hi Sergio, 

Greetings from Syncfusion Support. 

We have prepared a sample, such that data source for the resources has been assigned in ngOnInit function, which can be viewed from the following link, 

Please try the above sample, if you have any concerns please revert us back for further assistance. 


SE Sergio July 25, 2019 12:37 PM

Hi again,

Few hours ago I could resolve my problem, but thanks for the support anyway!

As I supposed, simply refreshing the scheduler component makes all the data appears on it without problems, so I attached a #mySchedule tag on the schedule html component, and then call the refresh method like this:


I hope this could help somebody else

KK Karthigeyan Krishnamurthi Syncfusion Team July 25, 2019 10:56 PM

Hi Sergio, 
We are happy that your problem has been fixed 😊 

Live Chat Icon For mobile
Up arrow icon