views:

136

answers:

4

I have an asp.net C# .net 3.5 page which contains several user controls. I am noticing that sometimes the html loaded on the browser is incomplete. It seems to get cut-off.

Any suggestions on how to troubleshoot whats the root cause?

+3  A: 

This can be symptomatic of server errors or proxy problems. I would use Fiddler to check what's going back and forth between your browser and the server. If you are getting any 500 (server error) response codes, that would be a good place to look.

Another thing to check would be javascript errors on the page, because depending on what your javascripts are doing, errors can prevent loading of other content in some cases.

womp
this is happening as i debug from VS 2008 on local machine!
That's fine, you can still use Fiddler. Instead of using "localhost" when you access your devel server, use "somesite.com", and Fiddler will kick in. Somesite.com has been registered to be aliased to 127.0.0.1 so that will trick Fiddler into analyzing the traffic.
womp
not sure how fidler ill help if this is on the code side. Something is shooping off only this page of the website, nothing else.
The point is that Fiddler will show you at exactly what point the HTML from the site is being terminated, which may provide a clue as to what is causing such termination. For instance, if the HTML is terminated at exactly the 16384th byte, it's a clue that the problem is probably caused by some filter (ISAPI/HTTP Filter) etc.
EricLaw -MSFT-
eric- thats very interesting. I will give it a try. Anything else to look for besides the 16384th byte?
one more thing, I am getting this error not on IIS, but on the local VS debugging webserver - that one shouldnt have any filters
A: 

womp probably has most of the bases covered, but the other angle that can lead to issues like this would be exceptions getting eaten but causing processing to stop, thereby sending half the page or somesuch.

Wyatt Barnett
A: 

Verify that your HTML is being written to the page by viewing the source code of the page after it loads. My guess is that the HTML that is being output is invalid, and that the browser isn't able to properly display it. Make sure all your HTML tags are properly closed and balanced.

It could also be an issue with the request being ended midway through. Try removing one control at a time from the page and see if the situation improves. If it does, you'll know which control is to blame.

Tim S. Van Haren
so it does not seem to be the HTML. Even in the source code of the browser I see the HTML being cut-off. In other words from some point on the code is missing.
A: 

It is quite unlikely that it is the same problem, but I had that happen before where the page had a custom filter attached to response.filter which reformatted the output to fix up some dotnet SEO problems. And the one we wrote had a bug where one regular expression consumed a bit too much copy in some instances and broke the output

Vdex
dont have anything touching the response... there is something at the request, but doubt would be that. Seems specific to this page, some interaction.