Does anyone know this?

  • Thread starter Thread starter john
  • Start date Start date
J

john

Hello,

I am trying to create a delegate for an upgrade but I am now getting
this error:

Method 'Public Function CamEventCallbackFunc(eventID As Integer, pData As
Integer, DataSize As Integer, Context As Integer) As Integer' does not have
the same signature as delegate 'Delegate Function
DelegateCDRegisterEventCallbackFunction(hSource As Integer, pFunc As
Integer, Context As Integer, ByRef hFunc As Integer) As Integer'.

Delegate Function DelegateCDRegisterEventCallbackFunction(ByVal hSource As
Integer, ByVal pFunc As Integer, ByVal Context As Integer, ByRef hFunc As
Integer) As Integer

Declare Function CDRegisterEventCallbackFunction Lib "CDSDK.dll" (ByVal
hSource As Integer, ByVal pFunc As DelegateCDRegisterEventCallbackFunction,
ByVal Context As Integer, ByRef hFunc As Integer) As Integer

err_Renamed = CDRegisterEventCallbackFunction(m_hSource, AddressOf
CamEventCallbackFunc, 100, m_hFunc)
 
Make sure the CamEventCallbackFunc method signature ends with

...., ByRef hFunc As Integer) As Integer

rather than

...., ByVal hFunc As Integer) As Integer



Mattias
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top