Created
June 28, 2015 12:15
-
-
Save nickdarnell/3bc23f0c39998dbcdddc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public sealed class MyPackage : Package | |
{ | |
private DTE mdte; | |
protected override void Initialize() | |
{ | |
// Your package is also a service container IServiceContainer | |
serviceContainer = this as IServiceContainer; | |
// The DTE object contains most of the goodies you'll want to play with | |
mdte = serviceContainer.GetService(typeof(SDTE))as DTE; | |
// I could also add a service of my own if I wanted | |
// serviceContainer.AddService(typeof(MyService), new MyService(), true); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment