Hi all,
I have created a project which contains an Interface with
few methods in it. I have built it and made the dll.

In another project I have added reference to this dll and
tried to implement the interface. When I am compiling the
second project. It is giving me two errors. Weirdly both
the error are coming for same methodname.

1. '<typename>' must implement '<methodname>' for
interface '<interfacename>'

2. '<methodname>' cannot implement '<methodname>' because
there is no matching function on interface'<interfacename>'

Surprisingly the error is not coming for the rest of the
methods on the interface. I have verified the signature of
the method. Infact I have used the methodname dropdown to
implement the method, which creates signature
automatically.

If anyone have the solution for the problem, please let me
know.

Thanks in advance
Hitesh.

Re: Problem with Interface Implementation by Rob

Rob
Thu Jul 24 00:23:24 CDT 2003

Can you post the interface method and the implementation of that method?

-Rob [MVP]

"Hitesh" <hkhatri@nexgenix.com> wrote in message
news:080a01c351a1$62fe18b0$a401280a@phx.gbl...
> Hi all,
> I have created a project which contains an Interface with
> few methods in it. I have built it and made the dll.
>
> In another project I have added reference to this dll and
> tried to implement the interface. When I am compiling the
> second project. It is giving me two errors. Weirdly both
> the error are coming for same methodname.
>
> 1. '<typename>' must implement '<methodname>' for
> interface '<interfacename>'
>
> 2. '<methodname>' cannot implement '<methodname>' because
> there is no matching function on interface'<interfacename>'
>
> Surprisingly the error is not coming for the rest of the
> methods on the interface. I have verified the signature of
> the method. Infact I have used the methodname dropdown to
> implement the method, which creates signature
> automatically.
>
> If anyone have the solution for the problem, please let me
> know.
>
> Thanks in advance
> Hitesh.
>



Re: Problem with Interface Implementation by Hitesh

Hitesh
Thu Jul 24 00:47:46 CDT 2003

Signature in the interface is:

Function MethodName(ByRef strCName As Object, ByRef
strAName As Object, ByRef strAValue As Object, Optional
ByRef strRID As String = Nothing, Optional ByRef strWID As
Object = Nothing, Optional ByRef strLID As Object =
Nothing, Optional ByRef strPID As Object = Nothing)


Implementation code is:


Public Function MethodName(ByRef strCName As Object, ByRef
strAName As Object, ByRef strAValue As Object, Optional
ByRef strRID As String = Nothing, Optional ByRef strWID As
Object = Nothing, Optional ByRef strLID As Object =
Nothing, Optional ByRef strPID As Object = Nothing) As
Object Implements NameSpace.InterfaceName.MethodName


....... My Code is here

End Function


I also tried to change it to Sub (at both places), but it
didn't help.

Thanks in advance for your help.
Hitesh


>-----Original Message-----
>Can you post the interface method and the implementation
of that method?
>
>-Rob [MVP]
>
>"Hitesh" <hkhatri@nexgenix.com> wrote in message
>news:080a01c351a1$62fe18b0$a401280a@phx.gbl...
>> Hi all,
>> I have created a project which contains an Interface
with
>> few methods in it. I have built it and made the dll.
>>
>> In another project I have added reference to this dll
and
>> tried to implement the interface. When I am compiling
the
>> second project. It is giving me two errors. Weirdly both
>> the error are coming for same methodname.
>>
>> 1. '<typename>' must implement '<methodname>' for
>> interface '<interfacename>'
>>
>> 2. '<methodname>' cannot implement '<methodname>'
because
>> there is no matching function on
interface'<interfacename>'
>>
>> Surprisingly the error is not coming for the rest of the
>> methods on the interface. I have verified the signature
of
>> the method. Infact I have used the methodname dropdown
to
>> implement the method, which creates signature
>> automatically.
>>
>> If anyone have the solution for the problem, please let
me
>> know.
>>
>> Thanks in advance
>> Hitesh.
>>
>
>
>.
>