Thanks for the reply.
I've tried using Sys.Desktop.ActiveWindow, however, I got similar results as previously.
The progress dialog I am trying to pick up should be displayed for a minimum of 2 seconds, however, if a large file is being processed it will display for longer.
In the 2 second example Sys.Desktop.ActiveWindow only seems to pick up the parent window and not the progress dialog.
In the example where it is processing for longer (and the progress dialog is displayed for longer) Sys.Desktop.ActiveWindow will pick up the progress dialog and I am able to calculate the display time.
Repeatedly logging the return value from Sys.Desktop.ActiveWindow.Name after clicking the button shows that script is being executed quick enough to pick up the progress dialog (i.e. well within 2s of clicking the button) it just doesn't seem to realise that the progress dialog is there.
Thanks
Mike