By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,215 Members | 1,920 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,215 IT Pros & Developers. It's quick & easy.

Stop VS.Net from reformatting my aspx pages

P: n/a
Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.
Nov 18 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
HI Abhishek,

Have you tried changing the options in Visual Studio .NET so that it
doesn't reformat code? If you've already done that and the problem
remains, I'm afraid that's all that you can do. The story here is not a
very good one. We are dependent upon MSHTML, the HTML rendering engine we
use in VS.NET. Unfortunately, MSHTML sometimes doesn't do a good job of
preserving your code formatting exactly the way you're formatted it.

The good news is that we've worked extremely hard to address this in
Whidbey, the next version of Visual Studio .NET.

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
ja******@online.microsoft.com

This post is provided as-is with no warranties and confers no rights.
--------------------
Date: Mon, 09 Feb 2004 17:54:33 +0530
From: Abhishek Srivastava <ab*****************@nospam.net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.6b) Gecko/20031208X-Accept-Language: en-us, en
MIME-Version: 1.0
Subject: Stop VS.Net from reformatting my aspx pages
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Message-ID: <#g**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.vstudio.development,microsoft.pub lic.dotnet.framework.aspne
tNNTP-Posting-Host: atlrel2.hp.com 156.153.255.202
Lines: 1
Path: cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!TK2MSFTNGP10.
phx.gblXref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208534 microsoft.public.vstudio.development:4309X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.


Nov 18 '05 #2

P: n/a
I think its funny, I posted a question similar to this about two months ago
and never got a response. You would think this YES un-turn-off-able
"feature" would cause a pretty big outroar, but very few people mention it.
I think it's all a conspiracy, Microsoft wants to standardize HTML output,
and our monitors aren't compatible with the mind probe they are using to
control everyone else's brain to just accept the badly formatted tags. No
wait, I've been watching too much TV, actually I heard once there should be
an option to turn this off in the next release. I know that doesn't provide
too much comfort to you now, you can do what I had to do... live with it.

"Abhishek Srivastava" <ab*****************@nospam.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.

Nov 18 '05 #3

P: n/a
I think ASP.NET Web Matrix supports custom markup layout today (won't "fix"
personal styles). Info at
http://asp.net/webmatrix/default.asp...dex=4&tabId=46.

"Michael Ramey" <raterus@localhost> wrote in message
news:OA**************@TK2MSFTNGP11.phx.gbl...
I think its funny, I posted a question similar to this about two months ago and never got a response. You would think this YES un-turn-off-able
"feature" would cause a pretty big outroar, but very few people mention it. I think it's all a conspiracy, Microsoft wants to standardize HTML output,
and our monitors aren't compatible with the mind probe they are using to
control everyone else's brain to just accept the badly formatted tags. No
wait, I've been watching too much TV, actually I heard once there should be an option to turn this off in the next release. I know that doesn't provide too much comfort to you now, you can do what I had to do... live with it.

"Abhishek Srivastava" <ab*****************@nospam.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.


Nov 18 '05 #4

P: n/a
I beautify my code. do proper indentation, close all tags. put every
attribute in quotes. And then savee the file.

And VS.Net goes and sh*ts all over it. Indentation is totally horrible,
All my <br/> become <br> align='center' becomes align=center. I hate its
html editor. (but for complex pages there is no other way but to go in
html mode and edit.)

I want to keep my html as well formed as possible. But VS.Net does
totally the opposite. Which is wierd because VS.Net boasts of XML
compatibility everywhere ... yet it will remove closed tags from my code??

I think this is a bug. Atleast programmers should be given a choice
whether they want to keep all tags closed (except some lage html things
like <input type'checkbox' selected>) and all attributes in quotes.

regards,
Abhishek.

Ed Kaim [MSFT] wrote:
I think ASP.NET Web Matrix supports custom markup layout today (won't "fix"
personal styles). Info at
http://asp.net/webmatrix/default.asp...dex=4&tabId=46.

"Michael Ramey" <raterus@localhost> wrote in message
news:OA**************@TK2MSFTNGP11.phx.gbl...
I think its funny, I posted a question similar to this about two months


ago
and never got a response. You would think this YES un-turn-off-able
"feature" would cause a pretty big outroar, but very few people mention


it.
I think it's all a conspiracy, Microsoft wants to standardize HTML output,
and our monitors aren't compatible with the mind probe they are using to
control everyone else's brain to just accept the badly formatted tags. No
wait, I've been watching too much TV, actually I heard once there should


be
an option to turn this off in the next release. I know that doesn't


provide
too much comfort to you now, you can do what I had to do... live with it.

"Abhishek Srivastava" <ab*****************@nospam.net> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl.. .
Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.



Nov 18 '05 #5

P: n/a
> The good news is that we've worked extremely hard to address this in
Whidbey, the next version of Visual Studio .NET.
That's really good news. When is the new edition coming out?

regards,
Abhishek.
Jim Cheshire [MSFT] wrote:
HI Abhishek,

Have you tried changing the options in Visual Studio .NET so that it
doesn't reformat code? If you've already done that and the problem
remains, I'm afraid that's all that you can do. The story here is not a
very good one. We are dependent upon MSHTML, the HTML rendering engine we
use in VS.NET. Unfortunately, MSHTML sometimes doesn't do a good job of
preserving your code formatting exactly the way you're formatted it.

The good news is that we've worked extremely hard to address this in
Whidbey, the next version of Visual Studio .NET.

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
ja******@online.microsoft.com

This post is provided as-is with no warranties and confers no rights.
--------------------
Date: Mon, 09 Feb 2004 17:54:33 +0530
From: Abhishek Srivastava <ab*****************@nospam.net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.6b)


Gecko/20031208
X-Accept-Language: en-us, en
MIME-Version: 1.0
Subject: Stop VS.Net from reformatting my aspx pages
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Message-ID: <#g**************@TK2MSFTNGP10.phx.gbl>
Newsgroups:


microsoft.public.vstudio.development,microsoft.pub lic.dotnet.framework.aspne
t
NNTP-Posting-Host: atlrel2.hp.com 156.153.255.202
Lines: 1
Path:


cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!TK2MSFTNGP10.
phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208534


microsoft.public.vstudio.development:4309
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.


Nov 18 '05 #6

P: n/a
Abhishek,

There is no hard date yet.

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
ja******@online.microsoft.com

This post is provided as-is with no warranties and confers no rights.

--------------------
Date: Tue, 10 Feb 2004 10:52:27 +0530
From: Abhishek Srivastava <ab*****************@nospam.net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.6b) Gecko/20031208X-Accept-Language: en-us, en
MIME-Version: 1.0
Subject: Re: Stop VS.Net from reformatting my aspx pages
References: <#g**************@TK2MSFTNGP10.phx.gbl> <RA**************@cpmsftngxa07.phx.gbl>In-Reply-To: <RA**************@cpmsftngxa07.phx.gbl>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Message-ID: <u7**************@TK2MSFTNGP10.phx.gbl>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: atlrel2.hp.com 156.153.255.202
Lines: 1
Path: cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!TK2MSFTNGP10.
phx.gblXref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208791
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
The good news is that we've worked extremely hard to address this in
Whidbey, the next version of Visual Studio .NET.


That's really good news. When is the new edition coming out?

regards,
Abhishek.
Jim Cheshire [MSFT] wrote:
HI Abhishek,

Have you tried changing the options in Visual Studio .NET so that it
doesn't reformat code? If you've already done that and the problem
remains, I'm afraid that's all that you can do. The story here is not a
very good one. We are dependent upon MSHTML, the HTML rendering engine we use in VS.NET. Unfortunately, MSHTML sometimes doesn't do a good job of
preserving your code formatting exactly the way you're formatted it.

The good news is that we've worked extremely hard to address this in
Whidbey, the next version of Visual Studio .NET.

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
ja******@online.microsoft.com

This post is provided as-is with no warranties and confers no rights.
--------------------
Date: Mon, 09 Feb 2004 17:54:33 +0530
From: Abhishek Srivastava <ab*****************@nospam.net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.6b)


Gecko/20031208
X-Accept-Language: en-us, en
MIME-Version: 1.0
Subject: Stop VS.Net from reformatting my aspx pages
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Message-ID: <#g**************@TK2MSFTNGP10.phx.gbl>
Newsgroups:


microsoft.public.vstudio.development,microsoft.pub lic.dotnet.framework.aspne t
NNTP-Posting-Host: atlrel2.hp.com 156.153.255.202
Lines: 1
Path:


cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTN GP08.phx.gbl!TK2MSFTNGP10. phx.gbl
Xref: cpmsftngxa07.phx.gbl
microsoft.public.dotnet.framework.aspnet:208534
microsoft.public.vstudio.development:4309
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Hello All,

I am developing a page which has a complex layout. This layout cannot be
made using VS alone, so I have to go into the html view and edit the
html myself.

The problem is that everytime I save the file, (or add/remove any
component to the page) VS.Net reformats and re-edits the whole page.

I find this very irrating because VS.Net totally disorganizes my code.
It removes all the quotes so align='center' becomes align=center

<td>
Hello
<td>

becomes
<td>
Hello</td>

I capitalizes / decapitalizes strings arbitrarily.

sometimes it also adds some extra </tr> to my code making my layout go
haywire.

I want to know if there is someway I can tell it to stop reformatting
and re-editing my code.

regards,
Abhishek.



Nov 18 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.