Solved

Public Not Creatable objects

Posted on 1998-10-08
4
634 Views
Last Modified: 2008-02-20
I am creating an Active X component to use with a standard exe program that must use Public Not Creatable as the instancing type. I have been told to create an object using 'Specials' as the type in the std exe, and a provide a method in the Active X component that returns the address of single (global) 'Specials' object in the Active X server. The std exe should then be able to access the single object and its methods. What does 'Specials' type mean?  How do I return the address of the global object? How do I go about this? I am a novice VB5 user.  
0
Comment
Question by:tlaver
  • 2
4 Comments
 

Author Comment

by:tlaver
ID: 1438984
Edited text of question
0
 
LVL 1

Accepted Solution

by:
abhinavm earned 200 total points
ID: 1438985
I don't know where you read this 'Specials' word. the meaning of PublicNotCreatable is that you can't create the instance of that class by using New or CreateObject. You have to provide one more object which is pulically creatable and which interns create this object and passes the reference to the program.
  for example you can't create the rdoconnection obejct by just saying new or create object you have to use the openconnection method of rdoenvironments to create rdoConnection.

0
 

Author Comment

by:tlaver
ID: 1438986
Thanks for the reply - I'll just check that I understand correctly: so now I will code a send object which will create my Public Not Creatable object. Then I create this second object from my other program (the standard exe) and ask the second object for the address of the object it created.

Now - if thats right - ho exactly to I get the address of the first object from the second object?
0
 
LVL 2

Expert Comment

by:joefunsmith
ID: 9593999
just a note on this older question... I think what tlaver was told to create; "an object using 'Specials' as the type" meant that he was to create a user-defined public data type called 'Specials' in the COM component that could be used in the standard exe.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question