c# - React on Visual Studio Stop -


is there possibility run code when code stopped when running visual studio?

i using cefglue library build winforms application , realized there issues when pressing stop button ranging exception 2 windows no content opening. separate process continues run in background. in order stop cef nicely need exectue cefruntime.shutdown(); maybe because not run application in visual studio hosting process, because cefglue has problem (see this). not affect production nasty while developing , testing, nevertheless execute code fix problem.

i guess not possible if interesting know.

so looking way execute code when visual studio stopping application when pressing stop button while in development.

note: using visual studio 2013 , 2015.

edit issue not reproducibly few lines of code. nevertheless have tried create simplified example here

what basicly looking solution using visual studio sdk.

you can build own add-ins implementing idtextensibility interface.

in onconnection function can subscribe different events. using (dte2)application can access a lot of things vs.

you'll have subscribe of events can obtained events property.

you'll have find out events work best solution. debuggerevents seem place start.

this require research before can use it. there easier solutions.

as simple example onconnection:

public void onconnection(object application, ext_connectmode connectmode, object addininst, ref array custom) {     var applicationobject = (dte2)application;      var events = _applicationobject.events;     var buildevents = (buildevents)events.buildevents;     buildevents.onbuildbegin += new _dispbuildevents_onbuildbegineventhandler(onbuildbegin); } 

this triggers when build started. available documentation isn't great, need trial-and-error before find need.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

javascript - Get parameter of GET request -

javascript - Twitter Bootstrap - how to add some more margin between tooltip popup and element -