473,770 Members | 1,901 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Macro Error 2950

21 New Member
Greetings:

I have been working on a database and have found a peculiar error.

When I open up my database and choose a form called "add inventory", then click on "view reports" and then, finally, double click on a report to view it shows up correctly.

However, I have created a search form that does not allow any changes but view/read only. I have the identical command to "view reports" as the "add inventory" form. When I click on the link "view reports" the form pulls up correctly. However when I attempt to double click on any of the reports I received an error.

Specifically it states:
An expression you entered is the wrong data type for one of the arguments.

You tried to run a macro or use a method to carry out an action, but an expression evaluated to the wrong data type.
For example, for the Close method you specified a string for the Object Type argument, but this argument can be set only to certain intrinsic constants or their numeric equivalents.


When I click "OK" an Action Failed window pops up:

Macro Name:
View Reports Macros.lstRepor ts : On Dbl Click

Condition:
True

Action Name:
OpenReport

Arguments:
Report by Location, 2, ,

Error Number:
2950


I am currently running Office 2007 and the database is Trusted.

What perplexes me is that the "View Reports" form/window works in one editable form however when the same form/window is called from a non-editable form the forms do not work? Why? They are all being called by the same Macro...

I welcome any information.

Thanks!
Nov 11 '08 #1
1 13279
missinglinq
3,532 Recognized Expert Specialist
The problem you describe along with the error message you report doesn't make a lot of sense, but that's not really unusual with Access! The error messages that appear often have no real relation to the errors that have occurred!

The control you're trying to click on is apparently named

lstReports

which I'm guessing, from its prefix of

lst

is a Listbox. If this is correct, I suspect that this is the problem. Comboboxes and Listboxes, on a Read-Only form, are essentially locked, and you cannot make a selection from them, which is what you're attempting to do. I think you're going to have to change your form from Read-Only to get the results you want.

Linq ;0)>
Nov 11 '08 #2

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

Similar topics

1
6694
by: TJRobertsJob | last post by:
Was wondering if someone could help. Over the last month I've been developing a small database application, using Access 2000, for use in a friends shop. Everything was going well until about a week ago when I started getting the following error when I would click any buttons on my main form that ran either VB code or an Access Macro: "Error accessing file. Network connection may have been lost.". I know for sure it's not a network...
1
1573
by: Dan | last post by:
I can't figure out this error message. Could someone please help. I have a text file in Notepad with the following 4 fields (Cont, Code, List, and Numb)all of which are single tab delimited, and a bunch of rows with values. I tried to create a macro (with the TransferText action) that would automatically import the values from those fields into an Access table called TestingTable which i created with the exact same field names and text...
0
2065
by: mvdkwong | last post by:
I am trying to run a macro that will export a table into a fixed length file (see below). However, when I run it, I get the following error: "Cannot update. Database or object is read-only." I've tried a few things that I found in postings, but I'm not getting anywhere. Please advise on what I can do. '------------------------------------------------------------ ' mcr_Export_Test '
2
6021
by: MLH | last post by:
What does it mean if I get a "Reserved Error" #2950 when running Application.SaveAsText acModule, "AutoExec","c:\TextFile" ???
7
2540
by: rudevincy | last post by:
Hello I am new to VBA and I am trying to create this program however I get the run time error 3061 Too few parameter expected_1, what does this mean, my code is: Sub Template_Provider_Retail(Spinner As String) Dim rs As Recordset Dim strSQL As String Dim i As Integer Dim IsSmall As Boolean Dim IsInsuf As Boolean
0
1123
by: =?Utf-8?B?amtyYW1vczIwMDU=?= | last post by:
Hi, I had received some help earlier in the week with regards to writing a Change Macro for Excel. Now I am getting an error message and I wanted to confirm why. Below is the part of the code that is highlighted with I get the error message: Run-time error '1004': Method 'Range' of object_Worksheet failed
10
25947
sueb
by: sueb | last post by:
I've done a lot of database work, but only scratched the surface with Access. I'm trying to write a macro (executable on-click from a button on a form) that will clear a subset of the current record's fields. My macro is pretty simple-minded: It has eight actions (all SetValue), each one associated with one of eight fields ("items", right?--selected off the table's field list), and each target expression is simply "null". I've associated...
0
1221
by: masood2k | last post by:
Hi, I try to use vbforms with access database and i am getting error "error 2950 reserved error" if leave open database file in access and use vb forms it works, close access program error comes..... please reply thanks
4
7268
by: nebula53 | last post by:
Please find the attached Data base When I changed the design of the Main form the macro stopped working properly How can I fix it so when I open my Data base the ( Main form ) open automatically as the interface of my Data base.
0
9454
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10259
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10101
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10038
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9906
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8933
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7456
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6710
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

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.