Task Class relation to Package

I have a custom package and I have written a class that inherits the Task class to help in my build process. Is there any relation between the Task class and the Package I'm trying to figure out how to access the OutputWindow from my Task class. I found some sample code like this, but I'm not sure how to access GetService from my Task class.

IVsOutputWindow outputWindow = GetService(typeof(SVsOutputWindow)) as IVsOutputWindow;

Mike



Answer this question

Task Class relation to Package

  • tamtaly

    You can call Microsoft.VisualStudio.Shell.Package.GetGlobalService(...) from anywhere to get a service.

    Craig



  • Task Class relation to Package