Report Export to Excel

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I have an application which programatically exports a number of reports all
of which are modal. When the export is carried out it is successful however
my application then freezes. and then has to shut down via windows task
manager.

When the reports are non-modal, they export normally and my application
continues to function normally.

The reports have to be modal in order to interact with JAWS software which
requires a particular window class to interact with my application correctly.

Any ideas?

Thanks,

Bernard
 
Bernard:

Why not create two buttons on your form, one for preview when printing or
outputting to Jaws and the other when you'll export. Create a global
variable in a module something like

Global boolRptModal as boolean

In your report's On open Event add code that looks to that variable to see
if the report should open modal

E.g. If boolRptModal = False then Me.Modal = False

And in the On close event of the report simply always reset the variable

boolRptModal = True

Then when exporting, open the reports like this:

boolRptModal = False
DoCmd.TransferSpreadsheet .....
 
Back
Top