Hello Gang!
Got a question!
I am working on a Form that allows the user to select reports to print.
The form has a display field called "txtstatus" that displays verbage to the usage to keep them informed of what is going on.
Basically, when the user selects the PRINT button, this field should have text placed in it to show the user what is happening in the background while they are waiting for a SQL SELECT to finish it's business, then display the REPORT FORM preview.
But what happens is, as soon as I press the PRINT button, the form ignores doing a refresh or repaint, and does not show any change to the txtstatus field UNTIL the REPORT FORM preview is display. WHEN that happens, the txtstatus field is show with the message that was placed in it earlier.
Here is the code to the PRINT button.
LPARAMETERS tlExport
LOCAL lcTheFile, lcExportFile, ldPrintDate
ThisForm.txtStatus.value = "Preparing report for " + DTOC(DATE()) + "..."
lcTheFile = "c:\temp\SIGlist"
SELECT * FROM sig INTO TABLE (lcTheFile) ORDER BY verbage
SELECT (lcTheFile)
IF !Thisform.p_Series
DO CASE
CASE tlExport = .T.
lcExportFile = PUTFILE("Export To","c:\siglist","XLS")
IF !EMPTY(lcExportFile)
SELECT (lcTheFile)
EXPORT TO (lcExportFile) TYPE XLS
ENDIF
CASE ThisForm.chkPreview.value = 1
REPORT FORM SIGLIST NOCONSOLE TO PRINTER PROMPT PREVIEW
OTHERWISE
REPORT FORM SIGLIST NOCONSOLE TO PRINTER PROMPT
ENDCASE
ELSE
REPORT FORM SIGLIST NOCONSOLE TO PRINTER
ENDIF
ThisForm.txtStatus.value = "Ready"
I've tried adding a ThisForm.txtStatus.refresh, ThisForm.refresh, and ThisForm.paint.
No good. Any ideas on what may be making the form to ignore the refresh and paint?
Thanks!!
Tommy Tillman A+ NetWork+ MCP