asp.net

Response does not start with HTTP

Attached Firefox to fiddler and got following error. What would cause this error? Interesting thing to note is that the HTTP header is getting rendered on the page So Fiddler says that there is a protocol violation because response does not start with HTTP. But the HTTP response is rendered on page. ...

What is the aspnet_client folder in my ASP.NET website?

I inherited a website and see that folder in the web root. I'm trying to clean out the old crap, and wondering if I can delete it. What is this folder used by? Is it auto generated? Is it a cache? What creates it? ...

Is there a way to use .aspx pages as templates for emails being sent from a winform application?

ASP.NET is great for creating html. We send out a lot of html email messages. In the past we've been loading .html templates with key strings that are replaced to make the email more custom (ie. [[FirstName]] would be replaced with "John Doe"). However as we are adding more and more email campaigns the logic to customize the email is...

Are there nested master pages in ASP.NET MVC?

I wanted to know if the MVC framework can leverage the Nested Master Page? If so does anyone have some info on how to achive this? ...

Set an async trigger for an Update Panel with a GridView asp:ButtonField

What is correct sytnax for setting an AsyncPostBackTrigger for an UpdatePanel with an asp:ButtonField from an GridView control? I need to set an 'AsyncPostBackTrigger' for each asp:ButtonField in my GridView Here is my source code <asp:UpdatePanel ID="MyUpdatePanel" runat="server" ChildrenAsTriggers="true" UpdateMode="Conditional"> ...

Using endResponse in a Response.Redirect

While performing a response.redirect in an ASP.NET page, I received the error: error: cannot obtain value for two of the variables being passed in (one value being retrieved from the querystring, the other from viewstate) I've never seen this error before, so I did some investigating and found recommendations to use the "False" value f...

Two text boxes, either one or both are required

I have two textboxes on an asp.net webpage, either one or both are required to be filled in. Both cannot be left blank. How do I create a validator to do this in asp.net? ...

Is ASP.Net (MVC) redirecting to the log in form when I generate a HttpUnauthorizedResult?

I'm actually using ASP.Net MVC, but I think this applicable to ASP.Net as well. Investigating how authorization works I've reached the conclusion that ASP.Net MVC generates an HttpUnauthorizedResult when the user is not authorized and should be. And then ASP.Net reads from my Web.config: <authentication mode="Forms"> <forms loginUrl...

ASP.NET Membership - Is authenticated user lost when you call a WebService in the same WebApp

I am using the ASP.NET Login Control for authentication. I have some users and they are able to login successfully. When authenticated I redirect to a page helloworld.aspx. In the Page_Load method I first make a call to Membership.GetUser(). This returns the authenticated user properly. I then make a call to a simple WCF web service...

Sending emails from code - Frameworks

I'm currently writing a web application that sends out various emails with dynamic textual content using the SmtpClient and MailMessage .net API classes - I just find I'm drowning in a sea of stringbuilders. Are there any email/templateing frameworks to help with this sort of thing? That also work in medium trust. ...

error running asp.net 1.1 and 2.0 together

So here is the error that I am trying to help a friend with (I don't think I would have tried this). He has a legacy Asp.net 1.1 application. He has already added some ASP.NET 2.0 features to his application. His app is running on a Windows 2003 server. He has the main application running in a 1.1 app pool. In one of the sub folder...

What are asp .net validators rendered into in HTML?

Are all asp net validators rendered as < span> tags? This is important as spans are being used in the styling and a strict css heiracrchy is in place and I don't want to add redundant < span> tags around what will be rendered at runtime. ...

ASP.NET Using Twitterizer in Medium Trust

Does anyone using the Twitterizer framework have any experience running it in a Medium Trust environment? I keep getting security exceptions... Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please conta...

Can you change the back color of an asp.net textbox when it is disabled?

When I set Enabled to false, it sets the background of the textbox to a grey color, can this be changed? Right now, the grey background with black text makes it a little hard to read. Or maybe, I have to use the readonly property instead and set the backcolor myself, is this correct? ...

Is ScriptReference order always conserved at runtime?

I've been bitten in the past by Page.RegisterClientScriptBlock-registered JS not being emitted in a stable order from machine to machine in the bad old .Net 1.1 days. Now, I'm writing a set of user controls that use <asp:ScriptManager/> to reference JS, and although I haven't had any problems so far - order always seems to be conserved ...

How do I dynamically create new Hyperlinks in ASP.NET?

I'll explain what I'm trying to achieve: I want to have a situation where I can create as many controls as I want by creating them in a loop in the code behind. I can do this while using PHP, by mixing the PHP code and the HTML code. This allows me to generate actual HTML tags dynamically. In ASP.NET, I haven't found a way to replica...

MySQL connection in ASP.NET references Issue

I have some code written that is attempting to connect to a mysql db. I have installed this. I have added a reference which is MySql.Data.CF.dll in the project. The project compiles with no complaints. When I execute this... string conn_str = ConfigurationManager.ConnectionStrings["MySQLServer"].ConnectionString; DataSet m_Dst = new Da...

Dynamic Business Rules in a web application

Greetings! Working on a web based project were business rules and logic need to be customized by client. I want to do this without having to recompile the application every time we sign up a new client on the system. The architectures I have outlined so far are: Windows Workflow: Creating dynamic workflows and saving them to the dat...

linq error

Hi I am working on a mobile.net project. I am trying to make a list of restaurants which is displayed in a drop down list...whn d user selects an item he can add it to d list of favorites. However i am getting an error Description: An error occurred during the compilation of a resource required to service this request. Please review th...

Why is Context.User null on ASP.NET Master Page now?

I just swiched to a new ASP.NET host and it seems it is behaving differently. In the code for the master page it is attempting too do some different logic for authenticated users by this. if (Context.User.IsAuthenticated) { } But the Context.User object is null. But it's only null on the master page. If I use it on the regular page it...