Has anyone ever used W$PROGRESSDIALOG to track C$COPY or are there any examples of how this is used?
In my test program, regardless of how long the C$COPY takes, the progress bar does not open until the copy finishes. At that point it opens, progress goes from 0 to 100% and then it closes.
From reading the documentation it seemed that setting WPROGRESSDIALOG-C-COPY before I begin the copy would mean there is no need to use WPROGRESSDIALOG-SET-PROGRESS. I've also tested with a call to WPROGRESSDIALOG-RESET-TIMER before the copy but there is no change.
Below is the code I am currently using.
*
Load-To-Server.
perform Progress-Setup.
call "C$COPY" using src-file-name(1:src-fn-sz)
temp-import-name
giving fileops-status
end-call.
perform Progress-Destroy.
.
*
Progress-Setup.
| create progressdialog
call "w$progressdialog" using WPROGRESSDIALOG-CREATE,
"title"
"message during cancel"
WPROGRESSDIALOG-AUTOTIME
WPROGRESSDIALOG-ANIMATION-FILECOPY
giving pd-handle.
| monitor c$copy
call "w$progressdialog" using WPROGRESSDIALOG-C-COPY,
Pd-Handle.
.
*
Progress-Destroy.
call "w$progressdialog" using WPROGRESSDIALOG-DESTROY
Pd-Handle.
.