[mono-vb] VB.NET AddressOf operator
ksathyasudha at novell.com
Fri Aug 26 05:48:42 EDT 2005
Right now, 'Delegates' in mbas are not in a very good shape. We too
have encountered this error many times, but didnt have a chance to look
into that. Will try to address it soon.
>>> Jesse van den Kieboom <jesse at icecrew.nl> 08/24/05 5:21 PM >>>
I'm quite new to VB.NET and mono and I'm having the following problem.
I'm trying to pass a function as an argument to a sub. The sub should
then execute the 'callback' and use its return value.
I declared a delegate:
Public Delegate Function HandlesType(type As Type) As Boolean
Further on I have the sub:
Protected Sub FindClasses(pHandles As HandlesType)
And a call:
FindClasses(New HandlesType(AddressOf CheckInterfaceType))
CheckInterfaceType conforms to the delegate declaration. Now mbas
(invoked from monodevelop) gives me the following error:
Could not find delegate constructor
at: FindClasses(New HandlesType(AddressOf CheckInterfaceType))
I've tried the same construction in SharpDevelop win32 (not mono) and it
worked fine. Is this a known issue?
Also a delegate doesn't seem to have an Invoke method which it does have
Jesse van den Kieboom
Mono-vb mailing list
Mono-vb at lists.ximian.com
More information about the Mono-vb