I have a report with a front-end in Excel (inherited files). There are multiple buttons calling VBA code which then call either SQL queries, stored procedures or R script files (in the form of rcmd batch/shell, passing some parameters etc.)
R scripts are called from VBA one after another. All need some unspecified time to finish.
There are applications/wait-time in the VBA to 'ensure' that the R script is finished before next step is initiated.
This does not always work (depends on the data size etc.).
Is there a way for / code to be put at the end of the R script that would notify VBA it is time to go on?
Or for VBA to check if the specific R script is still running?