VS2010 Text Editor: How do I set the default formatting style for inline code blocks?
Posted
by nukefusion
on Stack Overflow
See other posts from Stack Overflow
or by nukefusion
Published on 2010-04-21T12:16:21Z
Indexed on
2010/04/21
12:23 UTC
Read the original article
Hit count: 706
I've got a problem with the formatting of inline code blocks within the VS2010 text editor and wonder if anyone else has had similar problems and found the 'magic' setting I'm looking for.
I'm working my way through tutorials in an MVC book. Whenever I add some inline code blocks to a view I want them formatted like so:
<% foreach (var link in Model) { %>
<a href="<%=Url.RouteUrl(link.RouteValues)%>">
<%=link.Text%>
</a>
<% } %>
What I'm actually getting is this (auto-formatted by the IDE when I finish writing the code):
<% foreach (var link in Model) {
%>
<a href="<%=Url.RouteUrl(link.RouteValues)%>">
<%=link.Text%>
</a>
<% }
%>
It's pretty irritating. Any ideas on how I can instruct the IDE to leave my <% %> tags alone? I've been fiddling with options under "Tools -> Options -> Text Editor" for ages but alas am getting nowhere...
© Stack Overflow or respective owner