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 / IDE / April 2004

Tip: Looking for answers? Try searching our database.

Iterating projects with Enterprise Templates

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Daniel Cazzulino [MVP XML] - 29 Apr 2004 22:19 GMT
Hi there,
I'm trying to iterate and retrieve all C# and VB projects in a solution. The
solution has enterprise template projects, so I need to know the constant to
use to compare with teh Project.Kind property, or something like that.
Any help is much appretiated, thanks!

Signature

Daniel Cazzulino [MVP XML]
Clarius Consulting SA
http://weblogs.asp.net/cazzu
http://aspnet2.com

Daniel Cazzulino [MVP XML] - 29 Apr 2004 23:29 GMT
Working:

     DTE vs = (DTE) context.GetService( typeof(DTE) );
     if ( vs == null ) throw new InvalidOperationException(
SR.Gral_ServiceUnavailable( typeof(DTE) ) );

     ArrayList list = new ArrayList();
     Projects ps = (Projects) vs.GetObject("CSharpProjects");
     if ( ps != null )
     {
       foreach ( Project p in ps )
       {
         list.Add( p.Name );
       }
     }
     ps = (Projects) vs.GetObject("VBProjects");
     if ( ps != null )
     {
       foreach ( Project p in ps )
       {
         list.Add( p.Name );
       }
     }

:D

Signature

Daniel Cazzulino [MVP XML]
Clarius Consulting SA
http://weblogs.asp.net/cazzu
http://aspnet2.com

> Hi there,
> I'm trying to iterate and retrieve all C# and VB projects in a solution. The
> solution has enterprise template projects, so I need to know the constant to
> use to compare with teh Project.Kind property, or something like that.
> Any help is much appretiated, thanks!

Rate this thread:







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.