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

IDispatch Invoke with VARIANT array

Vic
Hi all!

I'm trying to create a DLL in C++ that calls an EXE containing a COM
component.
I load the component and call to it's methods using the IDispatch
interface, it works correctly until I try to call a method with the
signature:

method(long, BSTR, VARIANT*)

that is a method with and array of VARIANTS as parameter.
¿Have I to use SAFEARRAYBOUND? ¿has anybody an example of using it?

Many thanks!
Jul 19 '05 #1
1 8088

"Vic" <vi********@yahoo.es> wrote in message
news:25**************************@posting.google.c om...
Hi all!

I'm trying to create a DLL in C++ that calls an EXE containing a COM
component.
I load the component and call to it's methods using the IDispatch
interface, it works correctly until I try to call a method with the
signature:

method(long, BSTR, VARIANT*)

that is a method with and array of VARIANTS as parameter.
¿Have I to use SAFEARRAYBOUND? ¿has anybody an example of using it?

Many thanks!


Please ask this in a COM programming group, it has nothing at all to do with
C++.

john
Jul 19 '05 #2

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

Similar topics

0
by: | last post by:
well, how can i convert these code to VB.NET? thx CallJScript(const CString strFunc, const CStringArray& paramArray) { CComPtr<IHTMLDocument2> m_spDoc; m_spDoc.Attach(...
0
by: Pawel Janik | last post by:
Hello. I'm writing an application that calls com components. One of out parameters returns variant or type VT_DISPATCH, thast maps come C++ structure. This parameter is of System.__ComObject...
5
by: Dominic Godin | last post by:
Hi, I have decleared the IDispatch interface but I'm having trouble using it. Word.Application MSWord = new Word.ApplicationClass(); IDispatch wb = (IDispatch)MSWord.WordBasic; int lcid =...
1
by: Dmitry Medvedev | last post by:
Hello, I need to write C# class, that would implement IDispatch interface to be used in ActiveScript. I can't use IReflect interface here due to design issues, I need to handle GetIDsOfNames...
8
by: Charles Law | last post by:
Hi guys There's nothing much going on in Interop at the moment, so I'll post this here as well in case someone can give me a quick answer. The following is an extract from MSDN: <extract>...
0
by: Jim Hubbard | last post by:
How would I implement the IDispatch interface to handle the following in VB.Net <BEGIN> Controlling Download and Execution The WebBrowser Control gives you control over what it downloads,...
0
by: bramoin | last post by:
I have function with the signature: func_name( long numOuts, VARIANT _RPC_FAR *errorCode, VARIANT _RPC_FAR *errorString, VARIANT _RPC_FAR *state, VARIANT _RPC_FAR * returnArray, inputArray) ...
1
by: fraca7 | last post by:
Hello. I got a little problem while using pythoncom to automate IE; for some reason, changing the 'selectedIndex' on an instance of IHTMLSelectElement doesn't fire the 'onchange' event (I guess...
4
by: eselk | last post by:
I've got an out-of-process COM server (EXE) that I want to be able to control from Visual Basic. I can already control it from a C/C++ app without any issues. Under VBA in MS Access 2000, which I...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
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...

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.