Visual Studio - 整理变量声明
Visual Studio 中是否有任何捷径来整理变量声明。
例如,我正在通过编写一个方法来工作,并且因为我更关注该方法的逻辑而不是整洁性,所以我可能会在顶部声明我认为需要的变量,然后在需要时再声明一些变量,例如我继续。
string myString, mySecondString;
myString = "Foo";
mySecondString = "Barr";
string forgotINeededThisOne = String.Format("{0} - {1}", myString, mySecondString);
有什么方法可以快速执行此操作:
string myString, mySecondString, forgotINeededThisOne;
或者我需要手动执行此操作吗?
谢谢
Is there any short cut in Visual Studio to tidy up Variable Declaration.
For example, I am working my way through writing a method, and because I am focusing more on the logic of the method than on tidiness I maybe declare the variables I think I need at the top, then a few more as I need them as I go on.
string myString, mySecondString;
myString = "Foo";
mySecondString = "Barr";
string forgotINeededThisOne = String.Format("{0} - {1}", myString, mySecondString);
Is there any way I can quickly do this:
string myString, mySecondString, forgotINeededThisOne;
Or do I need to do this manually?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论