Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hi i was wondering where i could find some good tutorials covering VS 2003 maro editor. The thing i am wondering how to do with macros (now there will be more questions) is what event do i code so that i can add text whenever a .h file is created. for example if i wanted every header file created to start with

#ifndef [headername]_[iD]
#define [headername]_[iD]

#endif

and yes i know that you can use things like #pragma once, and im pretty sure theres a command line option that can be set in VS2003 but more important that just this use is how to do it, and where i can find easy to read help on coding the macros.

I would assume that others probably would find this usefull too.

Also on a side note over a year ago i found a macro (theres a link on this forum somewhere) that minimized all of the code when you loaded a project, if someone could post the link again or the code for the macro that'd be great.

Thanks in advance.

Posted

I'm having trouble finding any usefull Tutorials...

 

I think the thread you are looking for might be this one:

 

http://www.xtremedotnettalk.com/showthread.php?t=82454

 

The code therein confuses me however, for:

 

(1) There is a WindowEvents_WindowCreated() Event that Handles WindowEvents.WindowCreated, howevever, there is no 'WithEvets' variable or AddHandler contruct that is calling it.

 

(2) It looks like the following should generate a RTE, for myWindow = Nothing when myWindow.Count is accessed:

Dim myWindow As Window
While myWindows.Count > 0

However, I know almost nothing about VS Macros, and so maybe I just don't understand how they work? Not sure.

 

Hope this helps...

Posting Guidelines

 

Avatar by Lebb

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...