Update content of existing Loading


#1

Is there a way to update the contents of an overlay component? In this case Loading?

As I have multiple actions happening in the back, I would like to notify user about that changes without dismissing loading and creating a new one.

thanks


#2

Have you done this yet?


#3

Hey Omar, no I didn’t, I’m using only one…


#4

Hello Davor,

If found a solution using ngZone,

Here is an example:
> this.ngZone.run(() => {
if (progressEvent.lengthComputable) {
this.uploadingPercentage = Math.round((progressEvent.loaded / progressEvent.total) * 100);
this.loading.setContent("Uploading " + this.uploadingPercentage);
}
});