We have a report that uses vfp9 - see below. However if you preview the report then click print on the printer toolbar, system gets rebooted (no error message or anything - but a black screen). Any ideas or has anyone heard of this?
** To PDF
LOCAL pToolBar, lcPreviewCaption
pToolBar = CREATEOBJECT("CREATEPDF")
pToolBar.SHOW()
pToolBar.DOCK(0)
_REPORTPREVIEW = "ReportPreview.app"
_REPORTOUTPUT = "ReportOutput.app"
lcPreviewCaption = GetRealLabel("INQUIRY", "1013") && function that calls caption name
oRepForm = CREATEOBJECT("Form")
WITH oRepForm
.CAPTION = lcPreviewCaption
.WINDOWSTATE = 2 &&This will maximize the form
.SHOW()
ENDWITH
glNoLoad = .T. && prevents opening a new form from menu
_SCREEN.clsNavbar.combo1.enabled = .F. && disable chortcut pulldown combobox
_SCREEN.Closable = .F.
REPORT FORM FESI501 PREVIEW WINDOW (oRepForm.NAME)
** To PDF
LOCAL pToolBar, lcPreviewCaption
pToolBar = CREATEOBJECT("CREATEPDF")
pToolBar.SHOW()
pToolBar.DOCK(0)
_REPORTPREVIEW = "ReportPreview.app"
_REPORTOUTPUT = "ReportOutput.app"
lcPreviewCaption = GetRealLabel("INQUIRY", "1013") && function that calls caption name
oRepForm = CREATEOBJECT("Form")
WITH oRepForm
.CAPTION = lcPreviewCaption
.WINDOWSTATE = 2 &&This will maximize the form
.SHOW()
ENDWITH
glNoLoad = .T. && prevents opening a new form from menu
_SCREEN.clsNavbar.combo1.enabled = .F. && disable chortcut pulldown combobox
_SCREEN.Closable = .F.
REPORT FORM FESI501 PREVIEW WINDOW (oRepForm.NAME)