Click to See Complete Forum and Search --> : Visual Basic


ashobha
February 4th, 2000, 03:02 PM
Hi,
I have a C++ function implementation for a COM Object as follows

foo(Variant *var, String Text)..

I need to create this COM object and call the above mentioned function from visual basic.
I cannot find an equivalent to Variant * in VB?? I am getting typemismatch for Variant (obviously)

Thanks
Shoba

Johnny101
February 4th, 2000, 04:02 PM
Try using

Dim YourVariable as Variant
'set the value of YourVariable
Call Foo(YourVariable,strText)



I admit, I'm not familiar with C++ but it looks like you're looking for a variable type that can hold anything - in VB thats the Variant type.

If I'm wrong, then I'm sorry, but that's my guess. :)
John

John Pirkey
MCSD
www.ShallowWaterSystems.com