PC Review


Reply
Thread Tools Rate Thread

Can EnvDTE be imported into a VB application?

 
 
Dean Slindee
Guest
Posts: n/a
 
      10th Aug 2004
I would like to count lines in a project using code in a VB form. Need
EnvDTE as an Imports statement. Can this be done?

If so, I would then recode the following into VB:
foreach (EnvDTE.Project project in applicationObject.Solution.Projects)

{

LocalLines=0;

foreach (EnvDTE.ProjectItem item in project.ProjectItems)

{

count(item);

}

report.AppendFormat("{0}: {1} lines\r\n", project.Name, LocalLines);

Lines+=LocalLines;

}



Thanks,

Dean Slindee


 
Reply With Quote
 
 
 
 
Herfried K. Wagner [MVP]
Guest
Posts: n/a
 
      10th Aug 2004
* "Dean Slindee" <(E-Mail Removed)> scripsit:
> I would like to count lines in a project using code in a VB form. Need
> EnvDTE as an Imports statement. Can this be done?
>
> If so, I would then recode the following into VB:
> foreach (EnvDTE.Project project in applicationObject.Solution.Projects)


Add a reference to "Microsoft Development Environment 7.0" ("dte.olb"),
then import the namespace/class.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>
 
Reply With Quote
 
Ken Tucker [MVP]
Guest
Posts: n/a
 
      10th Aug 2004
Hi,

http://msdn.microsoft.com/library/de...gdteobject.asp

Ken
----------------------
"Dean Slindee" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
I would like to count lines in a project using code in a VB form. Need
EnvDTE as an Imports statement. Can this be done?

If so, I would then recode the following into VB:
foreach (EnvDTE.Project project in applicationObject.Solution.Projects)

{

LocalLines=0;

foreach (EnvDTE.ProjectItem item in project.ProjectItems)

{

count(item);

}

report.AppendFormat("{0}: {1} lines\r\n", project.Name, LocalLines);

Lines+=LocalLines;

}



Thanks,

Dean Slindee



 
Reply With Quote
 
Dean Slindee
Guest
Posts: n/a
 
      11th Aug 2004
Thanks to both of you, just what I needed.

"Dean Slindee" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I would like to count lines in a project using code in a VB form. Need
> EnvDTE as an Imports statement. Can this be done?
>
> If so, I would then recode the following into VB:
> foreach (EnvDTE.Project project in applicationObject.Solution.Projects)
>
> {
>
> LocalLines=0;
>
> foreach (EnvDTE.ProjectItem item in project.ProjectItems)
>
> {
>
> count(item);
>
> }
>
> report.AppendFormat("{0}: {1} lines\r\n", project.Name, LocalLines);
>
> Lines+=LocalLines;
>
> }
>
>
>
> Thanks,
>
> Dean Slindee
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
what is EnvDTE GS Microsoft C# .NET 2 5th Jun 2007 10:47 PM
envDTE and events Steph Microsoft C# .NET 1 24th Oct 2006 07:17 PM
Which namespace should be imported to handle application in .dll files? Owen Wong Microsoft ASP .NET 1 17th Mar 2006 12:29 PM
EnvDTE of CodeDom =?Utf-8?B?UHJhdGlr?= Microsoft Dot NET Framework 1 13th Sep 2004 01:02 PM
Instance EnvDTE.DTE Jindrich Hora Microsoft C# .NET 0 23rd Jul 2003 06:40 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:07 PM.