Question
7.3.1 Status bar/Progress bar updated while activity loops
Hi all. We have a pre-processing activity that could loop through up to 10,000 embedded pages to perform a series of checks or validations. This process could take a while to execute. I would like to provide the user with a browser message (i.e. alert(string)) that shows the percentage of the process as it is running. It cannot be UI-side since the preprocessing activity executes before the sections load.
I have been researching a java solution to input into the activity as a step that would update the percentage of progress with each iteration (1,082 of 10,000 Complete) or (10.82% complete). I'm open to any other ideas or options.
I tried looking into UI controls, but as stated, for obvious reasons, it cannot be done.
I tried adding alert("Hello World"); with java, but get a compile error that alert(string) is not defined.
Any help, suggestions, or ideas is greatly appreciated.
***Edited by Moderator Marissa to update platform capability tags****
Hello,
If I understand what you are asking, you are calling an activity that iterates through a bunch of data and you want to return values that the UI can consume and provide some sort of status updates? I'm not sure of how to do that, or if it's doable. Presumably you called this from the UI somewhere, and if in your activity you made a call like "show-property" you could send some sort of message back to the client. You would need handle that message in JavaScript or something, and that part is definitely outside of my domain. Calling JavaScript from within a Java step isn't going to work though. The Java will be running on the server, and the alert would need to be called on the client.
I hope that help helps,
- Mike