473,396 Members | 1,713 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,396 software developers and data experts.

mdb as reference problem...

I have an mdb with class modules that I use as a reference for another mdb.
The library is called MyLib.

I'm trying to declare variables in my front end mdb as class objects in the
library

Dim x as MyLib.ClassModuleName

This doesn't seem to work. When I type MyLib. and the intellisense pops up,
all I see are public functions and enums. I don't see any class module
names. How do I expose them?

Thanks.

Matthew Wells
Ma***********@FirstByte.net


Jul 11 '07 #1
3 1536
The way I work around this issue is to provide a public function in the
library which returns a new instance of the object:

Public Function New_ClassModuleName () as ClassModuleName
Set New_ClassModuleName=new ClassModuleName
End Function

"Matthew Wells" <Ma***********@FirstByte.netwrote in message
news:o9******************************@comcast.com. ..
>I have an mdb with class modules that I use as a reference for another mdb.
The library is called MyLib.

I'm trying to declare variables in my front end mdb as class objects in
the library

Dim x as MyLib.ClassModuleName

This doesn't seem to work. When I type MyLib. and the intellisense pops
up, all I see are public functions and enums. I don't see any class
module names. How do I expose them?

Thanks.

Matthew Wells
Ma***********@FirstByte.net


Jul 11 '07 #2
Matthew Wells wrote:
>I have an mdb with class modules that I use as a reference for another mdb.
The library is called MyLib.

I'm trying to declare variables in my front end mdb as class objects in the
library

Dim x as MyLib.ClassModuleName

This doesn't seem to work. When I type MyLib. and the intellisense pops up,
all I see are public functions and enums. I don't see any class module
names. How do I expose them?

Take a look at:
http://www.mvps.org/access/modules/mdl0034.htm

--
Marsh
Jul 11 '07 #3
This works great - with a few notes.

You don't have to rename the old class and create a new one. You can just
delete the code and import the text file.

When you import the text file, these lines will appear at the top. Just
delete them (unless someone knows something I don't).

VERSION 1.0 CLASS
BEGIN
MultiUse = -1 'True
End

Also, if you have any private classes that are used as parameters in the new
public class (paramaters and other stuff - you'll see in the error message),
you have to expose those classes as well.

But overall this is really GREAT!!

THANKS!!!


"Marshall Barton" <ma*********@wowway.comwrote in message
news:ns********************************@4ax.com...
Matthew Wells wrote:
>>I have an mdb with class modules that I use as a reference for another
mdb.
The library is called MyLib.

I'm trying to declare variables in my front end mdb as class objects in
the
library

Dim x as MyLib.ClassModuleName

This doesn't seem to work. When I type MyLib. and the intellisense pops
up,
all I see are public functions and enums. I don't see any class module
names. How do I expose them?


Take a look at:
http://www.mvps.org/access/modules/mdl0034.htm

--
Marsh

Jul 12 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Pkpatel | last post by:
Hi, I keep getting this error every time I try to load crystalreportviewer on a webform with a dataset. Here is the error: -------------------------------------------------------- Server...
6
by: trexim | last post by:
Hi, I am trying to create a Web Reference for CSTA using the URL http://www.ecma-international.org/standards/ecma-348/csta-wsdl/csta-wsdl-all-operations.wsdl Visual .Net complains that: "...
2
by: Suzanne | last post by:
Hi all, I'm reposting this message as I'm experiencing this problem more and more frequently : I really hope someone out there can help me as I've been tearing my hair out on this one for a...
2
by: Jake Barnes | last post by:
Using javascript closures to create singletons to ensure the survival of a reference to an HTML block when removeChild() may remove the last reference to the block and thus destory the block is...
3
by: Richard Lewis Haggard | last post by:
We are having a lot of trouble with problems relating to failures relating to 'The located assembly's manifest definition with name 'xxx' does not match the assembly reference" but none of us here...
5
by: Michael Russell | last post by:
Hi all, Using C#, I've created a simple wrapper class for using Excel. I have Office Pro 2003 installed on my devel machine. The wrapper class works great, reading and writing to/from Excel. ...
27
by: David W | last post by:
I'm almost tearing my hair out. A colleague claimed that a null reference can exist, like this: void f( int& p ) { printf( "%d\n", p ); } int main (int argc, char *argv) {
8
by: toton | last post by:
HI, One more small doubt from today's mail. I have certain function which returns a pointer (sometimes a const pointer from a const member function). And certain member function needs reference...
2
by: toton | last post by:
Hi, This is continuation of topic pointer & reference doubt. http://groups.google.com/group/comp.lang.c++/browse_thread/thread/df84ce6b9af561f9/76304d7d77f6ccca?lnk=raot#76304d7d77f6ccca But I...
29
by: shuisheng | last post by:
Dear All, The problem of choosing pointer or reference is always confusing me. Would you please give me some suggestion on it. I appreciate your kind help. For example, I'd like to convert a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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,...
0
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...
0
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...
0
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,...

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.