|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hey there guys,
Question here for all you Access gurus. Im currently building a reporting system based around an access database, and this involves outputting said reports to word-compatible files in Rich Text Format. Trouble is, when I run the code (by clicking a button on a form, the file is generated, but said action crashes access. Any idea what the problem may be?? Heres the line of code that is causing me great greif: DoCmd.OutputTo acReport, stDocName, acFormatRTF, Outfile, OpenView Outfile refers to a variable that is the name and path of the report that is outputted, and openview is a true/false variable that set whether the file should be opened for viewing or not (btw: same problem occurs when openview is true AND false.) Thanks, Brendon |
|
#2
|
|||
|
|||
|
Check if the Office .dll library is installed in References and test it again. If it still doesn't work, perform 2 more tests. 'Publish' the data from an Access report via Office tools, by selecting 'Publish it with MS Word' (the output is .rtf). The path can be specified in Options\General\Default database folder. Then, test the variables that when strung together, they are correct. This process of elimination will track down the error.
|
|
#3
|
|||
|
|||
|
No luck
Quote:
OK...I did that...and It still did it, however, I noticed that it happened when I had the forms running - all of which have VBA code sitting behind them. I checked out the event viewer and found this sitting there... Faulting application msaccess.exe, version 10.0.2627.1, faulting module msaccess.exe, version 10.0.2627.1, fault address 0x00035c0b. |
|
#4
|
|||
|
|||
|
Could you upload a zipped sample database? I would like to see the code behind the forms, if possible. I found the a posting on another website with the identical error codes from the Event log. The advice given there is to reinstall Office, but I doubt that. I suspect that the error may be in the code, or more likely in the rtf converter. I would like to replicate the error at work where I have clean setups on several workstations, Win2K and XP. Otherwise, I won't be home for another 7 hours. It is now 10:30am EST, Canada.
|
|
#5
|
|||
|
|||
|
Well I figured it
Turns out, all I had to do was go into report properties, and change the Modal and Popup flags to 'no'.....works fine now..
Thanks for your assistance all the same....have a good one.. One of those STLT'S (Stupid Little Things) |
|
#6
|
|||
|
|||
|
May I know how you solve?
U saying go to report properties, pop up set to no? I am using MS Access 97, I dun see such option in access report. However I encounter the same error message in windows 2003 server environment with MS Access 97 install. |
|
#7
|
|||
|
|||
|
For snowmanapril: It is not the report but the form's modality that has to be set to "No". (Form properties Modal = No).
For milsy: The popup property will not prevent you from viewing or exporting the .rtf file, but the best way is to hide the form using the report's On open event, while prviewing/printing the report and using the report's On close property to re-display the form. |
|
#8
|
|||
|
|||
|
my access juz using query and report without using form.
I still get error faulting msaccess.exe, no matter how many times i reinstall the office 97 |
![]() |
| Viewing: Dev Articles Community Forums > Databases > Microsoft Access Development > outputting reports to .rtf format from access |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|