MS Access report opens but quickly closes - ms-access

I have a MS Access database where the user will click a button to open a report. The report appears to be opening (white window for a few seconds; might be doing the query). But then the report just closes. It has happened to 2 users on 2 different reports, but same Database. This does not happen to me. And I'm the programmer of the database.
the "Docmd.OpenReport" is straight forward: open the report as a preview, no criteria.
I thought maybe the form is expecting a certain printer. so I printed with a printer, then deleted that printer. the problem was not replicated.
Anyone experience this? and any solutions?

Not sure if this helps, but I vaguely remember encountering a similar problem, and it was the result of records in the underlying query being locked while the report was being generated for preview. The command button code to open the form had On Error Resume Next; so no error was generated, the query didn’t run (due a record lock issue), and the report would just close with no error.

Related

Strange issue in SSRS 2016. I am unable to select parameters or run the report intermittently, it works fine most of the time

I am having a strange issue with SSRS 2016. We setup a new server and uploaded some reports, the reports ran fine for few days. The issue is, randomly the report doesnt run, When I load the report page, the parameters appear blank and I am unable to select any parameters. If I try to run and click the view reports button, nothing happens. After few mins/hours, it automatically resolves.
We have contacted MS support and could not get anything to get this resolved
Has Anybody faced a similar issue ?
This does not constitute an answer but it won't fit in a comment!
Does this affect more than one report?
If more than one, do they all fail at the same time or will one work and another not when you try to run the at the same time?
If the situation is "all fail" or "all work" at any single point in time then try adding a new report with no parameters.
If this attempts to run when other reports fail then it sounds like the datasource cannot be resolved or a timeout connecting to the database.
If your parameters are populated by querying the database the report will 'hang' until it can complete the queries to populate the parameters so by running a parameter-less report you should see an error instead.
Try running a trace on the database server to see if you can see the queries being run at all.
A bit vague I know but it might help you understand where the problem lies a little better.

SSRS 2015 hangs after two parameter changes

My question is about the following scenario:
In SSRS 2015 one report keeps refusing to render(hangs on a blank report) under specific circumstances.
Here is the scenario.
Open the report, which automatically renders (Functions perfectly)
Alter one parameter (it doesn't matter which one), render the report (Functions perfectly)
Alter a another parameter (It could be the same one or a different one), render the report. It hangs. There is no actual error shown, but the report just hangs with nothing displayed.
Specifically; The parameters are all greyed out and no report is rendered. The "View report" button is still visible and appears active, but nothing happens when you click on it.
The only way to make the report function again is to back completely out of it and re-enter the report from the beginning.
It is important to note that none of the sub-reports are effected. You can drill through to them as much as you like and nothing will hang.
Also, this functions perfectly on our 2012 server and that no other reports on either server have encountered this error.
I can't even replicate it in Visual Studio.
Has anyone ever seen anything like this?
Any insight would be appreciated.

Access takes a long time to open reports

I have an Access Database. When I try to open a report, either in Design view or Regular view, it takes nearly 2 minutes to open. This is a new behavior (everything was fine last week but after leaving my computer, and the DB, on over the weekend, this started) and even occurs when opening a report that has no data bound to it. Not sure if this matters, but the DB is split. This even happens with I try to programmatically open a report, using DoCMD. I've tried to compact and repair both sides, but this does not seem to help. Any ideas?
thanks
jason
Try to change the default printer of Windows.
Access reads the information from this when launching a report.

Access Subreport Shows In Print Preview But Doesn't Print/Export

I can't figure out what is going on with my report in Access 2010. When I run it, all the queries and recordsources are generated and the report shows up, perfectly full of data and formatted in print preview. If I try and print a hard copy or export to PDF, the subreports don't print. I have done compact and repair, closed and opened, and check everything I know, but it's not working. The only thing that I can think of is that the subreports are based on temp tables I generate and set within VBA after I pull all the parameters I need. But I don't see why this would cause it to preview but not print? Any help would be greatly appreciated!!
Here's the solution I found... when I moved the table creation code to the button that prompted the report rather than having it use the openargs in the open event of the subreport, it worked. Don't know why exactly it liked it one place better than the other, but I'm glad that it works now!
After many hours in research and experimentation the only solution was a third party print function: http://www.lebans.com/reporttopdf.htm. Leben’s function always produces a printable PDF with visible subreports.
No modification of the report’s properties was of any value, though this is suggested by various posts; it failed to work for me. Similarly, compact and repair failed to help, as did the creation of a wholly new MDB file and importing all the forms/tables/queries. I ran the MDB in Access 2003 and in Access 2010 on another machine and had the same failure.
This points of course to the issue being embedded within Access. Research shows this has been an issue plaguing Access for many years; in its inimitable lack of care for users getting work done Microsoft has failed to even comment on this, much less fix it.
I had a similar issue and thought that I should post my fix in case someone else runs into the same problem.
I had a report with two subreports on it. From a form, I would select from several combo boxes and then hit the button to run the report. When the report opened (in preview and in report-view) it looked fine, and the subreports worked fine. However, when I tried to print or save, the subreports would not show up.
My solution was in my queries and in the form. The report's source queries were pulling criteria from the combo boxes on the form. Once the report was run, the combo boxes would clear, thus clearing the criteria for the queries. After the report is run, the report looks at the queries again when you try to print/save.
If you have a similar setup, I would suggest checking your source queries again after the report is run to see if you are still getting results. You should see the same data in your queries and in your report. If not, there's where to start looking. Hope this helps anyone else struggling with the same issue.

Reporting Services 2005 - Printing Graph - An error occurred during printing. (0x80004005)

I am trying to print a report that contains a bar graph using the report viewer, but running into an error. My reporting server is running SQL Server 2005 Reporting Services SP3 on Windows Server 2003 SP2.
Here are some steps that will reproduce the problem (at least for me)...
On a clean machine, I open up the
report, and it displays fine.
I then click the print button, and I
am prompted to install the
RSClientPrint ActiveX control. The
control downloads and installs fine.
I then click the print button again,
and the print dialog appears.
I select a printer, and click "OK".
A message box appears that has the
following text (including the
spelling error)...
An error occured during printing.
(0x80004005)
Any other report I try to print works fine. The only difference between this report and the other ones is that it contains a bar graph. If I remove the graph from the report, redeploy it, and then re-run it, it prints without getting that error.
As far as I know, it is not isolated to a specific machine. It happens to every customer I have talked to, and a variety of machines here in the office.
Has anyone seen anything like this? I have seen similar posts on the web suggesting to uninstall video drivers on the reporting server (thinking the GDI dlls have become corrupt ), install service packs, etc. I have tried every suggestion, but haven't found a good solution yet.
Thanks.
I ended up having to use a paid Microsoft incident on this, but it is resolved now. The issue was that I had a matrix in my report that had dynamic columns. Depending on exactly which date range you picked, the report could have n number of columns. In my case, when a date range was chosen that produced three or more of these dynamic columns, it would cause the matrix to become too large and run outside of the margins of the report.
The report would run and display fine with the matrix being too large, but the incredibly non-descriptive error would display whenever the report was printed or exported.
I resolved the issue by reducing the size of other columns and the overall font size in the report. This prevents the matrix from running off the page in the case of date ranges that produce three dynamic columns. It doesn't solve it in the general case (four or more columns will make it fail), but is good enough for my current purposes.
Microsoft didn't have a fix for the general case (such as a way to make the matrix fixed width).
I figured I should answer this in case anyone else runs across it.
-David