PDA

Click to See Complete Forum and Search --> : Sending an array from VC to a VB OCX


selad
Feb 8th, 2001, 08:11 AM
Hello all,

I have a problem, which is bugging me for a few weeks now and I hope I will find the answer here.

I wrote an activex control in visual basic. The activex control has a method that one of the arguments is a “Variant” that expects an array.
Now I’m trying to use the control from VC++. The problem is how should I send the array from VC++ to the control.

For example, I attached a demo OCX (proTest.ocx) that have only one method (I had some problems attaching the file so it can be found here
http://www.optiwater.com/proTest.zip):

Public Function TEST(varArray As Variant) As Integer

The method expects varArray to be an array (no specific size). The array’s elements are shown in a message box – so use small arrays.

I would be very grateful for any ideas,

Elad Salomons

steveconner
Feb 13th, 2001, 09:52 AM
Answered in VB COM and ActiveX Forum