Hi Dennis,
I'm a little confused by observation 1. Is the size of the array different after the method call? That would seem to indicate a re-dimensioning by the activex component.
I don't have much in the way of more ideas, perhaps loading the array with 0's or chr(0)'s before sending. Have you examined the ActiveX control with the object browser to see if that reveals anything useful? I've dragged an interface on to an open prg or even the command window to see what a method wants and returns.
Good luck.
Gary
>Gary,
>
>>Perhaps the method wants a safearray of bytes (VT_UI1) passed by_ref
>>
>>DIMENSION lblobFingerPrnt[1000] as BYTE && The server should be able to re-dimension
>>COMARRAY(ptemplate,10) && Look at COMARRAY for other values
>>
>>lnResult = ptemplate.Export( @lblobFingerPrnt )
>>
>
>This is what I did:
>
>
>*** ActiveX Control Event ***
>LPARAMETERS ptemplate
>
>LOCAL lblobFingerPrint, lnResult, laFinger[1]
>
>WAIT WINDOW NOWAIT "Creating Employee Record..." NOCLEAR
>
>DIMENSION laFinger[1024] AS Byte
>COMARRAY( ptemplate, 11 )
>
>lnResult = ptemplate.Export( @laFinger )
>
>IF lnResult # Er_OK
> MESSAGEBOX( "Error in getting Registration Template" )
> RETURN
>ENDIF
>
>lblobFingerPrint = 0h
>FOR i = 1 TO ALEN( laFinger, 1 )
> WAIT WINDOW NOWAIT i
> lblobFingerPrint = lblobFingerPrint + laFinger[i]
>ENDFOR
>
>APPEND BLANK IN employee
>replace lastname WITH thisform.txtLastname.Value,;
> firstname WITH thisform.txtFirstname.Value,;
> fingerprnt WITH lblobFingerPrint IN employee
>
>WAIT CLEAR
>
>
>The following are my observations:
>
>1. The resulting size of lblobFingerPrint is ALWAYS equal to the length of the array multiplied by 1024. So, if I dimension the array laFinger to laFinger[12], it will get 12 x 1024.
>
>2. This means the ActiveX does not re-dimension the array.
>
>3. If I open the field FingerPrnt, it shows a big bunch of zeroes. How do you make of that?
>
>4. Using COMARRAY with an argument of 10 will cause laFinger array values to be 'numeric zeroes'.
>
>Thanks for helping!
>
>Dennis