Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / Extensibility / February 2006

Tip: Looking for answers? Try searching our database.

Where is IVSMDCodeDomProvider?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jesús López - 14 Feb 2006 15:08 GMT
Hi all,

I'm writting a Custom Tool in C# for VS 2005 by implementing IObjectWithSite
and IVsSingleFileGenerator. I based my code on the gotdotnet
BaseCodeGeneratorWithSite sample which I'm trying to migrate to VS 2005 with
no success. My problem is I cannot find the assembly that declares
IVSMDCodeDomProvider interface.

I found this interface in Microsoft.VisualStudio.Designer.Intefaces.dll and
all works fine if I reference this assembly. But this assembly is for VS
2003 and I'm using VS 2005.

I also tried to declare the inteface myself:

[ComImport, Guid("73E59688-C7C4-4A85-AF64-A538754784C5"),
InterfaceType((short) 1)]
public interface IVSMDCodeDomProvider
{
     [DispId(0x60010000)]
     object CodeDomProvider { [return: MarshalAs(UnmanagedType.IDispatch)]
[MethodImpl(MethodImplOptions.InternalCall,
MethodCodeType=MethodCodeType.Runtime)] get; }
}

But I'm not an Interop guy and I got InvalidCastException in the following
line of code:

IVSMDCodeDomProvider vsmdCodeDomProvider =
(IVSMDCodeDomProvider)GetService(CodeDomInterfaceGuid);

Regards:

Jesús López
VB MVP
Robert Simpson - 14 Feb 2006 15:53 GMT
That interface is in the VSIP SDK under
VisualStudioIntegration\Common\Assemblies\Microsoft.VisualStudio.Designer.Interfaces.dll

Robert

> Hi all,
>
[quoted text clipped - 30 lines]
> Jesús López
> VB MVP
Robert Simpson - 14 Feb 2006 16:06 GMT
Bah I didn't read your post thoroughly enough :)  You already found it in
there!

The interface definition hasn't changed, so you should be fine referencing
that library from VS2005.
Jesús López - 14 Feb 2006 17:17 GMT
Thank you Robert.

I referenced that assembly from VS 2003 folders and I've just realized the
assembly is also in VisualStudioIntegration\Common\Assemblies. So I guess I
have to install that assembly in the GAC when I deploy the custom tool ? I'm
not sure if the assembly is installed along side VS 2005.

Regards:

> Bah I didn't read your post thoroughly enough :)  You already found it in
> there!
>
> The interface definition hasn't changed, so you should be fine referencing
> that library from VS2005.
Robert Simpson - 14 Feb 2006 17:35 GMT
It's already in the GAC on my system ... I'm pretty sure its automatically
put there during the VS install so you won't have to distribute it.

Robert

> Thank you Robert.
>
[quoted text clipped - 10 lines]
>> The interface definition hasn't changed, so you should be fine
>> referencing that library from VS2005.
Jesús López - 14 Feb 2006 17:59 GMT
Thank you Robert

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.