I have taken a macro that i use and created a vs.net add in. I am having a
problem adding new files or items to the project. It worked fine in the
macro but i am not sure how to do this in the vs.net add-in.
In the macro i was able to do the following
DTE.ItemOperations.AddNewItem("Web Developer Project Files\Visual Basic\Text
File", "sp" & tname & ".txt")
My addin seems to error out on this line. I have tried a number of
variations but still without success.
Help please. thanks
dave
Hi Dave,
Which is the exact error that you are getting? Seeing your code, the only
thing that I see is the DTE root variable, which exists in macros but not in
add-ins. The OnConnection method receives an Application As Object parameter
that you must cast to a variable of the EnvDTE.DTE type and use it instead
of "DTE".

Signature
Best regards,
Carlos J. Quintero
MZ-Tools: Productivity add-ins for Visual Studio
You can code, design and document much faster:
http://www.mztools.com
>I have taken a macro that i use and created a vs.net add in. I am having a
> problem adding new files or items to the project. It worked fine in the
[quoted text clipped - 10 lines]
> Help please. thanks
> dave