473,406 Members | 2,390 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,406 software developers and data experts.

GUID is undefined ???


Code Sample:-

ATL Class

class CAtl : public IA, Public IB

{

---------

--------

virtual functions -- overridden of IA and IB

}

class MyClass : public CAtl

{

virtual methods again overridden

}

DEFINE_GUID(CLSID_MyClass, {---GUID---})

My Problem:

I have written a class (CAtl) which is deriving some COM interfaces
(IA and IB).

I have written one more class (MyClass) which is derived from
CAtl class.

I have overridden those virtual function of Interfaces in both of my
classes (in CAtl and also in MyClass).

I defined a new GUID for MyClass class.

Now i have to create Object of my class (CAtl) using CocreateInstance.
which is not working .....

it is saying that CLSID is undefined..what shud i do to register my
class and create its object.

Output file is a .lib

Please help me out

thanx

Now i want to create "Myclass" object using CoCreateInstance and error
is comming that GUID is undefined. How should i create its obj?
--
Posted via http://dbforums.com
Jul 19 '05 #1
1 3109
"agrsaurabh" <me*********@dbforums.com> wrote...

Code Sample:-

ATL Class

class CAtl : public IA, Public IB

{
[...]

DEFINE_GUID(CLSID_MyClass, {---GUID---})

My Problem:

I have written a class (CAtl) which is deriving some COM interfaces
(IA and IB).

I have written one more class (MyClass) which is derived from
CAtl class.

I have overridden those virtual function of Interfaces in both of my
classes (in CAtl and also in MyClass).

I defined a new GUID for MyClass class.
GUID has nothing to do with C++.
Now i have to create Object of my class (CAtl) using CocreateInstance.
which is not working .....
'CocreateInstance' is not defined by C++ language.

it is saying that CLSID is undefined..what shud i do to register my
class and create its object.

Output file is a .lib

Please help me out


Please post to a newsgroup where COM (OLE) is on topic. I suggest
looking among microsoft.public.* newsgroups, with 'com' in the name.

Victor
Jul 19 '05 #2

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

Similar topics

4
by: Louis Frolio | last post by:
Greetings All, I have read many upon many articles here regarding GUID data types and uniqueness. There have been many opinions regarding the effectiveness of GUID's and when they should/should...
9
by: Rene | last post by:
I am using the Guid.Empty value ("00000000-0000-0000-0000-000000000000") to represent a special meaning. The problem is that I don't know if there is a chance that a command like...
14
by: Nak | last post by:
Hi there, Does anyone know how I would get the value of the assembly GUID in code from within the same application? Thanks in advance. Nick. --...
5
by: rcolby | last post by:
Evening, Wondering if someone can point me in the right direction, on how I would compare a system.guid with a system.byte. system.guid (pulled from sql server table with a data type of...
5
by: George | last post by:
I want to create a unique id for each of a set of objects. These ids may be generated on multiple machines simultaneously and must all be different to each other. There are an undefined number...
1
by: Wolf | last post by:
Hi I am trying to set a property(PartyHomeAddressID) = to a guid in a ini file. But everytime when the ini file has an empty guid it breaks with an error tellin me a guid is 32 char long with 4...
5
by: Michael Primeaux | last post by:
I have a simple .NET 2.0 web service created with VS.NET 2005 with a single web method with the following signature: void HelloWorld(Guid parameter1); When calling this method I receive the...
2
by: Troll | last post by:
Windows XP Pro VS 2005 & C# (I'm fairly new to C# but have doing VB.Net going on 2yrs and VB6 for 5yrs.) I'm using C# to build a custom RSS generator. I'm having trouble building the guid...
4
by: Marc | last post by:
Hi, I don't get it I cannot get this to work, can somebody give me a hint Table1 contains a field Id which is a GUID as primary key and DATA a string, I want to insert a new row but it does not...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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
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...
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,...
0
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...

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.