Set a project default for VB.NET projects so that the default Modifiers property for controls is Private

早过忘川 提交于 2019-12-10 13:19:11

问题


Is it possible to set a project default for VB.NET winforms projects so that the default Modifier for controls added to winforms is Private (not Friend)?

I know there's a "modifiers" property in the properties window so I can set it for each individual control... however I would like to change the project so from now on myself and other developers have to specifically decide to change from private. (Which I would strongly discourage them from doing).

I believe there is no way of doing this, but on another forum a while ago someone mentioned it would be possible with an add-in (but didn't name the add-in or where to get it).


回答1:


It could be possible to build an addin to do this. C# or VB.NET

Once you have an Addin structure set in place you can do it on a button click (create a new button for them) or try and play it off of an add item event. I am still looking to see if I can find an event for you.



来源:https://stackoverflow.com/questions/2800618/set-a-project-default-for-vb-net-projects-so-that-the-default-modifiers-property

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!