grid and dhtmlx.message out of sink

From a grid I call a function to copy the grid to the clipboard, and then paste it into excel. I am wanting to display several messages in order to inform the end-user what is being done. Something like:

Copying Grid data to clipboard… please wait.

Clipboard copy finished…

Opening Excel

Finished …

My code below works – but is displayed AFTER the processes are complete; not in the order of the process. Standard “alert” messages work just fine – but the dhtmlx.message does not.

Also, is there any way for a “message” to be displayed … and not until another is sent is it removed?

Any help would be greatly appreciated!



function copyData(){
dhtmlx.message(“Grid Clipboard copy started… Please wait”);
dhtmlx.message(“Grid Clipboard copy finished.”);
dhtmlx.message(“Opening Excel…”);
var objExcel = new ActiveXObject (“Excel.Application”);
objExcel.visible = true;
var objWorkbook = objExcel.Workbooks.Add;
var objWorksheet = objWorkbook.Worksheets(1);
dhtmlx.message(“Excel paste operations started.”);
dhtmlx.message(“Excel paste operations finished.”);