开发者

VSPackage load order - load before another VSPackage?

开发者 https://www.devze.com 2023-01-15 10:01 出处:网络
How do you create a VSPackage that has a dependency on functionality i开发者_如何学Pythonn another VSPackage? In other words, if I have VSPackage A that exports a certain feature that I need in VSPack

How do you create a VSPackage that has a dependency on functionality i开发者_如何学Pythonn another VSPackage? In other words, if I have VSPackage A that exports a certain feature that I need in VSPackage B, how do I ensure that VSPackage B is loaded first?

Thanks Matt


Presumably, this is a VS Service that you're exposing from VSPackage B? If that's the case, Visual Studio will automatically load the package when you request it from VSPackage A via a call to Package.GetService.

There is also an API method to force-load a package, but using it generally means you're doing something wrong. :-) You should rely on VS to delay-load packages as necessary.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号