473,386 Members | 1,679 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,386 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 902

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: Shadow Lynx | last post by:
If this is not the most appropriate group for this question, please let me know. I noticed an odd priority difference in resolving names in VS 2005 (VWD Express) vs. the .NET 2.0 compiler (the...
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: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
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
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...

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.