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

name conflicts with PROPVARIANT, propidl.idl and #import

I'm currently moving our VC6 code base to VC7 (and test against VC8
Beta).

I have major problems #importing .idl files that use PROPVARIANT's.
I already played with different #import options (rename, exclude,
auto_rename, #defining the tag_inner_PROPVARIANT to PROPVARIANT etc.),
but with limited success. Either the PROPVARIANT used in the .tlh/.tli
interface wrappers is declared as a separate type from the "Windows"
type, or I have conflicting declarations.

This is complicated by a wrapper class (propvar_t) class being derived
from PROPVARIANT.
(One declaraiton makes PROPVARIANT a union, which you can't inherit
from)

Abstract:

// ---- .idl ---------
import "propidl.idl"; // added for VC7+
[...] interface IFoo : IUnknown
{
HRESULT Foo(PROPVARIANT pv);
};
....

// ---- .h ---------
#import "foo.tlb" rename_namespace("nsFoo") ...
class _propvar_t : public PROPVARIANT
{
// ...
// type cast operators and conversion constructors
};

// ---- .cpp ---------

IFooPtr pFoo;
pFoo.CreateInstance(__uuidof(Foo));

propvar_t pv(42l);
pFoo->Foo(pv);

// -------------------
Any help?

TIA
Peter

Nov 17 '05 #1
0 763

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

Similar topics

0
by: plb | last post by:
All: I am struggling with an import problem... In my package, myapp, there is a module called logging. This module, naturally, imports the standard library module logging. However, when I...
15
by: torched_smurf | last post by:
I have a java program in a package called 'cmd'. This of course conflicts with the builtin python package of the same name. The thing is, I need to be able to import from both of these packages in...
12
by: christopherlmarshall | last post by:
Suppose you want to write a subclass of some existing class you are importing from a module you didn't write and that you don't want to study the internals of, and you want to define a data member...
2
by: LoopyNZ | last post by:
Hi, (Access 97) I'm creating a query (QRY_SUMMARY) to join a query (QRY) to itself (QRY_1). I'm returning QRY.* and selected fields from QRY_1. With each field (field_name) I return from...
0
by: peterchen | last post by:
I'm currently moving our VC6 code base to VC7 (and test against VC8 Beta). I have major problems #importing .idl files that use PROPVARIANT's. I already played with different #import options...
5
by: Mike Nolan | last post by:
I have a 600K row table on my production system (running 7.3.3) that I dump and load on my development system (7.4.1) every night using cron jobs. I would like to be able to restore the table...
1
by: Christian Fröschlin | last post by:
I have an assembly "A" which contains a Windows Control and has been compiled with C# in .NET 1.0, and I have now attempted to use this from a C++ 2005 Windows Forms Application "B". I can add a...
1
by: brig | last post by:
Hi All, I have a Table (STDTable) with 3 columns: STDAccount, STDpassword, IRowId. I am getting a user conflicts error when I 'get the next' user info from the table. I am using SQLDeveloper. ...
2
by: Microsoft Newsserver | last post by:
Hi I have a web applications ( one with the dll ). and I have declared some classes. However, I keep getting warnings that the class c:\xxxx\xxxx\xxx.cs conflicts with the imported on the in...
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
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,...

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.