473,325 Members | 2,870 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Error when printing reports while running MDE but not MDF

91
This problem only occurs when running from the MDE file, works perfectly fine when trying it from the original MDF.

I have a command button that prints a report, except after pressing it, a error comes up: "The expression On Click you entered as the event property setting produced the following error:The OpenReport action was cancelled."

Does anyone have any idea what this could be from?
May 7 '10 #1
7 1926
missinglinq
3,532 Expert 2GB
If you need help in trouble-shooting code, it's a good idea to actually post the code!

Linq ;0)>
May 8 '10 #2
Could the report not have data? Do you trap the NoData event in the report?
May 9 '10 #3
matt753
91
Heres the code:

Expand|Select|Wrap|Line Numbers
  1. Dim rs As Recordset
  2.  
  3.     Set rs = frmsubAdminEdit.Form.Recordset
  4.  
  5.     rs.MoveFirst
  6.     Do Until rs.EOF
  7.  
  8.         If rs(7) > 0 Then
  9.  
  10.             DoCmd.OpenReport "rptInvoice", acViewNormal, , "OrderID=" & rs(0), , False
  11.             rs.Edit
  12.             rs(6) = -1
  13.             rs.Update
  14.  
  15.         End If
  16.  
  17.         rs.MoveNext
  18.  
  19.     Loop
  20.  
  21.     Set rs = Nothing
  22.  
Again, error when clicking this button happens only when the front end is a MDE, works fine when its a MDB. Error is: "The expression On Click you entered as the event property setting produced the following error:The OpenReport action was cancelled."
May 10 '10 #4
matt753
91
The report DOES have data in it
May 10 '10 #5
matt753
91
Any ideas anyone?

Has anyone else ever had weird issues that only happen in an MDE and not the MDB?
May 12 '10 #6
What's the error code? Looks like a NoData problem to me when you try to open the report. Does the NoData event trigger in the report when you run this? A simple MsgBox would be able to tell you.
May 17 '10 #7
matt753
91
It was actually due to an error in the code I had when the report was opening. It just didnt show that when doing it in this loop. Only when opened indiviudally.
May 17 '10 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Gary | last post by:
Hi, I am getting this error within vb.net when i try and print to a printer... "Value cannot be null." the line "e.Graphics.DrawImage9me.PictireBox1.Image,0,0)" is highlighted. My code...
0
by: Florin M | last post by:
I am running a custom application developed with ASP.NET 1.1, C# and Visual Studio 2003. I recently installed SP2 for XP Professional. When I close the Internet Explorer window where the app...
0
by: Florin M | last post by:
I am running a custom application developed with ASP.NET 1.1, C# and Visual Studio 2003. I recently installed SP2 for XP Professional. When I close the Internet Explorer window where the app...
2
by: aaronk321 | last post by:
Look below.. I'm baffled - what is going on? db2 => select tablespace_name from table(snapshot_tbs('epmdev01', -1)) as snapshot_tbs Do you want to execute the above command ? (y/n) y ...
1
by: Matt | last post by:
When I try to run the ASP.NET application, it has the following error messages: Error while trying to run project: unable to start debugging on the web server. The project is not configured to...
8
by: John | last post by:
Hi I have a perfectly fine running webform on the local server. When I upload the webform to a remote shared server I get the below error. Any idea what is causing this? Thanks Regards
2
by: Sara T. | last post by:
Friends, After I installed Windows XP SP2, I often found error when I running ASP.NET Web Application on my desktop. The error is shown as following: Configuration Error Description: An error...
0
by: Uma | last post by:
Dear all, I have a problem while running a smart client application which was installed through CD-ROM. After installing the smart client setup the application is running properly. When running...
3
by: Rafael Tejera | last post by:
I'm receiving this error when trying to run a C#2003 ASP.NEt application. The error is the following: Error while trying to run project: Unable to start debugging on the web server. You do...
5
by: mike | last post by:
I created a VB.NET app that uses Outlook's COM object. I get an error when I run master..xp_cmdshell 'myprogram.exe' in SQL query analyzer. The error occurs on this line "oOutlook = New...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.