-
VB Data Report Open
Hi,
I have a DataEnvironment and a DataReport in my Visual Basic project, in which I am using Access database. When I produce the report, during run-time, and when I close the report, and try to execute another SQL query to produce a second report I get an error, that the object (my DataReport) cannot stay open...
Can anyone pls help?
-
Re: VB Data Report Open
i dont know if this is right or if it can help but just try this.
on the terminate event of your query, set the datareport recordsource = nothing
-
Re: VB Data Report Open
the run-time error that appears is :
"Run-time error 3705: Operation is not allowed when the object is open"
And when I press "Debug" the error is located in line:
DataEnvironement1.Command1 mystr1
at the object DataEnvironment
-
Re: VB Data Report Open
I have the following code:
DataEnvironment1.Command1_Grouping mystr1
DataReport1.Show
and when this is executed for the first time I get the report and everything is ok.
when I close the report and try to show another report (with a different mystr1) I get the error:
"Run-time error 3705: Operation is not allowed when the object is open"
How can I close the object: ataEnvironment1.Command1_Grouping???
-
Re: VB Data Report Open
I meant the object:
DataEnvironment1.Command1_Grouping???
sorry