禁用“Auto ID元素”在Visual Studio 2013中 [英] Disable "Auto ID elements" in Visual Studio 2013

查看:209
本文介绍了禁用“Auto ID元素”在Visual Studio 2013中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在工具>选项中,找不到用于禁用在HTML源代码视图中粘贴的元素的自动重命名设置。

In Tools > Options, I cannot find the setting to disable auto-renaming of elements which are pasted in HTML source view.

它曾经是:工具>选项>文本编辑器> HTML>其他>自动ID元素粘贴在源视图中。

It used to be: Tools > Options > Text Editor > HTML > Miscellaneous > Auto ID elements on paste in Source view. But that option is gone in Visual Studio 2013.

如何禁用自动重命名?

推荐答案

现在最好的解决方案似乎是一个解决方法,由用户发布在 Microsoft Connect网站将代码粘贴为注释。

For now the best solution seems to be a workaround that was posted by a user on the Microsoft Connect website which is to paste the code as a comment.


扼杀IDE,我们没有粘贴代码(因此他不会改变它)。怎么样 ?粘贴评论!如何在现实生活中做到这一点?这里是我做的(随意建议其他方式!):

Fool the IDE that we're not pasting code (thus he won't alter it). How ? Paste a comment ! How to do that in real life ? Here is how I do it (feel free to suggest other ways!):

1)将光标放在我想粘贴代码
2)ctrl-k ,ctrl-c(即
注释区域,因为没有选择区域,空的注释是
插入,我们的光标在其中)3)ctrl-v(粘贴内容是
作为IDE的注释)4)ctrl-k,ctrl-u(即
取消注释我们当前的注释!

1) Place cursor where I want to paste code 2) ctrl-k, ctrl-c (i.e. comment region. Since no region was selected, an empty comment is inserted and our cursor Inside of it) 3) ctrl-v (paste content that is believed to be a comment by the IDE) 4) ctrl-k, ctrl-u (i.e. un-commenting the current comment we're in!

这篇关于禁用“Auto ID元素”在Visual Studio 2013中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆