check report is open

  • Follow


Hi all

I want to check if a report is open before running a bit of code on another 
report, is there a command to easily check for this?

Thanks, Sue 


0
Reply Sue 5/26/2010 3:05:25 PM

Application.CurrentProject.AllReports("NameOfReport").IsLoaded

-- 
Doug Steele, Microsoft Access MVP
http://www.AccessMVP.com/DJSteele
(no e-mails, please!)

"Sue" <sportybabesue@hotmail.co.uk> wrote in message 
news:%23JRCfTO$KHA.5292@TK2MSFTNGP06.phx.gbl...
> Hi all
>
> I want to check if a report is open before running a bit of code on 
> another report, is there a command to easily check for this?
>
> Thanks, Sue
> 


0
Reply Douglas 5/26/2010 3:32:47 PM


Thanks, great as ever :-)

"Douglas J. Steele" <NOSPAM_djsteele@NOSPAM_gmail.com> wrote in message 
news:udPb2iO$KHA.5464@TK2MSFTNGP05.phx.gbl...
> Application.CurrentProject.AllReports("NameOfReport").IsLoaded
>
> -- 
> Doug Steele, Microsoft Access MVP
> http://www.AccessMVP.com/DJSteele
> (no e-mails, please!)
>
> "Sue"  wrote in message news:%23JRCfTO$KHA.5292@TK2MSFTNGP06.phx.gbl...
>> Hi all
>>
>> I want to check if a report is open before running a bit of code on 
>> another report, is there a command to easily check for this?
>>
>> Thanks, Sue
>>
>
> 


0
Reply Sue 5/26/2010 3:47:28 PM

You could do something like:

If CurrentProject.AllReports("YourReportName").IsLoaded = True Then
    'If you are here, the report is currently open
End If
-- 
Hope this helps,

Daniel Pineault
http://www.cardaconsultants.com/
For Access Tips and Examples: http://www.devhut.net
Please rate this post using the vote buttons if it was helpful.



"Sue" wrote:

> Hi all
> 
> I want to check if a report is open before running a bit of code on another 
> report, is there a command to easily check for this?
> 
> Thanks, Sue 
> 
> 
> .
> 
0
Reply Utf 5/27/2010 9:23:42 PM

����
"Sue" <sportybabesue@hotmail.co.uk> д����Ϣ����:%23JRCfTO$KHA.5292@TK2MSFTNGP06.phx.gbl...
> Hi all
>
> I want to check if a report is open before running a bit of code on 
> another report, is there a command to easily check for this?
>
> Thanks, Sue
> 


0
Reply ο 5/31/2010 6:10:43 AM

4 Replies
335 Views

(page loaded in 0.19 seconds)

Similiar Articles:
















7/23/2012 8:15:41 AM


Reply: