Subreport


09-02-2008, 6:10 PM
I put a subreport in detail section

I want to know if the subreport is blank page or not when program running

I try run the subreport and test the currentpage is nothing or document.pages.count

But I find if I put obj.run in the following code, the subreport will not show up

the following code in detail1_format event

Dim obj as new activesubreport1
with obj
.a=A
.b=B
...
End obj
Set Me.subreport1.report=obj

obj.run
if subreport1.CurrentPage Is Nothing then
...
end if



Re: Subreport


09-03-2008, 2:08 PM
Thank you for your question. Please note subreports are not page aware, thus you will not be able to return the PageCount (They can simply be thought of as a control). If possible could you describe the reason you are attempting to achieve such functionality? If so I may be able to recommend an alternative approach.

Thanks,
    Eric