Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I prevent Visual Studio from renaming my controls?

If I paste something like

<asp:DropDownList ID="DropDownListExpirationDate" runat="server" /> 

onto an ASPX file that already has a control with ID DropDownListExpirationDate, it will rename the newly-pasted control as DropDownList1.

<asp:DropDownList ID="DropDownList1" runat="server" /> 

I'd rather it didn't. I'd rather it just paste exactly what I copied.

Is there a way to disable this feature?

like image 959
Zack Peterson Avatar asked Jan 27 '09 17:01

Zack Peterson


1 Answers

After a quick check(!)....

Tools > Options > Text Editor > HTML > Miscellaneous

Uncheck 'Auto ID elements on paste in Source view'.

like image 141
CJM Avatar answered Sep 23 '22 17:09

CJM