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 / General / February 2004

Tip: Looking for answers? Try searching our database.

File header macro - newbie

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Joe - 16 Jan 2004 14:01 GMT
Hi ..
Any idea how to create a visual studio macro that inserts file headers into c++ code files...
if you have any sample code please post it...
Thank you
Joe
Bill - 27 Feb 2004 23:59 GMT
If you use alt-F8 or alt-F11 and look at the Samples project of macros,
there's one in there that just simple text insertion for a function header
comment.  The Approximate Pseudocode is something like:
   sub InsertFileHeader ()
      ts as TextSelection = DTE.ActiveWindow.Selection
      ts.StartOfDocument
      ts.Insert("... my big string ...")

You could also use Tools->Macros->Start Recording and record typing in a
couple of lines of text after hitting ctrl-home and then going and editing
TemporaryMacro.  Rename it first to something you like because the next time
you record something, you'll clobber whatever is defined as TemporaryMacro.

Bill

> Hi ...
> Any idea how to create a visual studio macro that inserts file headers into c++ code files...?
> if you have any sample code please post it....
> Thank you!
> Joe

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.