Michael Mullan
25-May-2010, 09:32 AM
When I want to directly set properties in the report, I want to do it from a function within the report view, which I can call after the report has been created.
Unfortunately in all the various ways the VRWintegration wizard creates report views, the actual report object is "hidden" within another object.
To get around this I have added a function to the VRWPreviewPanel.dg modeled after OpenReport, called hOpenReport. This passes back to me the object handle for the report object, so I can talk at it directly.
In particular this will make it easier for me to report on Temp Files, using David Martinko's TempFile package.
Function OpenReport String sReportName Returns Boolean
String sReportId
Set psReportName of oReport to sReportName
Get OpenReport of oReport to sReportId
Function_Return (sReportId <> "")
End_Function
Function hOpenReport String sReportName Returns Handle
String sReportId
Handle hoReportID
Set psReportName of oReport to sReportName
Get OpenReport of oReport to sReportId
If ((sReportId <> "") Begin
Get Object_Id of oReport to hoReportID
Function_Return hoReportID
End
Function_Return 0
End_Function
Does this make enough sense to be included in the standard package? Is there a better way?
Unfortunately in all the various ways the VRWintegration wizard creates report views, the actual report object is "hidden" within another object.
To get around this I have added a function to the VRWPreviewPanel.dg modeled after OpenReport, called hOpenReport. This passes back to me the object handle for the report object, so I can talk at it directly.
In particular this will make it easier for me to report on Temp Files, using David Martinko's TempFile package.
Function OpenReport String sReportName Returns Boolean
String sReportId
Set psReportName of oReport to sReportName
Get OpenReport of oReport to sReportId
Function_Return (sReportId <> "")
End_Function
Function hOpenReport String sReportName Returns Handle
String sReportId
Handle hoReportID
Set psReportName of oReport to sReportName
Get OpenReport of oReport to sReportId
If ((sReportId <> "") Begin
Get Object_Id of oReport to hoReportID
Function_Return hoReportID
End
Function_Return 0
End_Function
Does this make enough sense to be included in the standard package? Is there a better way?