Thank you!

It worked when I moved the assembly into the same directory as the
executable. Now I know it is a deployment style issue rather than a coding
issue.

Thanks,

tom

-----Original Message-----
From: Unmoderated discussion of advanced .NET topics.
[mailto:[EMAIL PROTECTED] On Behalf Of Ivan Towlson
Sent: 14 July 2004 14:59
To: [EMAIL PROTECTED]
Subject: Re: [ADVANCED-DOTNET] Invoke .NET static methods in COM

Yes, even if the assembly is in the GAC, you still need to qualify the
type name.

As your assembly is strong named and in the GAC, you probably need to
provide a full assembly name with Culture/Version/PublicKeyToken
strings.  (Sorry, I overlooked this in your original message.)  This is
necessary because there could be multiple versions of the assembly in
the GAC.  I can never remember the format of these -- see the
AssemblyName class for documentation though I always find it easier just
to drop a test method into the type to output the
Type.AssemblyQualifiedName and copy that *grin*.

Does it work if the .NET assembly is in the same folder as your EXE
file?

--
Ivan Towlson
White Carbon



-----Original Message-----
From: Unmoderated discussion of advanced .NET topics.
[mailto:[EMAIL PROTECTED] Behalf Of Tom Hyland
Sent: 14 July 2004 13:45
To: [EMAIL PROTECTED]
Subject: Re: [ADVANCED-DOTNET] Invoke .NET static methods in COM


Is this the case even if the assembly is in the GAC?

I tried the code below anyway (my assembly is called ClassLibrary2 so I
used
"ClassLibrary2.Class1,ClassLibrary2" - that's right isn't it?) and it
still
fails in the same place.

Also, I looked in the registry, and ClassLibrary2.Class1 is there ok

Thanks, your help is much appreciated

tom

===================================
This list is hosted by DevelopMentorR  http://www.develop.com
Some .NET courses you may be interested in:

NEW! Guerrilla ASP.NET, 17 May 2004, in Los Angeles
http://www.develop.com/courses/gaspdotnetls

View archives and manage your subscription(s) at http://discuss.develop.com

===================================
This list is hosted by DevelopMentor�  http://www.develop.com
Some .NET courses you may be interested in:

NEW! Guerrilla ASP.NET, 17 May 2004, in Los Angeles
http://www.develop.com/courses/gaspdotnetls

View archives and manage your subscription(s) at http://discuss.develop.com

Reply via email to