passing an array to a COM object?
| From: | BCA - Jerry Jackson | Date: | Tue, 07 Nov 2000 19:26:21 +0000 |
| Subject: | passing an array to a COM object? | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-3715@lists.php.net to get a copy of this message | ||
I'm getting an error when attempting to pass an array to a COM object
as follows:
----------------------
Here's the PHP code:
$myarray[0] = "zero";
$myarray[1] = "one";
$myarray[2] = "two";
$myarray[3] = "three";
echo $ref->Test($myarray);
----------------------
Here's the VB code:
Public Function Test(strArray() As String) As String
Test = strArray(1)
End Function
-----------------------
Here's the resulting error message:
Warning: Invoke() failed: Type mismatch. in c:\inetpub\wwwroot\php-com.php
on line 22
-----------------------
It works fine when try to pass in and return a simple non-array string.
I know I'm doing something wrong on the PHP side of the fence....anyone know
the answer? Thanks!
-----------------------------------------------------------------
Jerry Jackson
Director of Software Development
BCA Technologies, Inc.
(407) 659-0653 ext. 320
jerry@bcatech.com
-----------------------------------------------------------------