Blog Archives

ASP.Net

File upload control fails first time, then works on subsequent submits

As everybody knows that FileUpload control doesn’t work inside update panel, there are some work around and in fact I have posted post about that as well.   Here is my post link just in case you got here and

Posted in Microsoft Technology Tagged with:

ASP.NET color converter tool

Wants to convert HEX to RGB or RGB to HEX in C# ASP.NET application? I have created Color Converter ASP.NET application.  You can convert HEX color code values to RGB Color.  It’s free tool.  I have also included source code

Posted in Microsoft Technology Tagged with: ,

why does Modalpopup close on postback?

ads: Watch Indian TV Serials Online I thought modalpopup control is very easy to use but it’s not.  It took me whole day to figure it out why ModalPopup Extender closes down during page postback. You should have to keep

Posted in Microsoft Technology Tagged with: ,

Response.Redirect() throws an error when called inside Update Panel

When I tried to call Response.Redirect() inside a UpdatePanel, it was throwing me an AJAX error. Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls

Posted in Microsoft Technology Tagged with: ,

How to: Bind Jagged array or Single dimension array to repeater control

In this article I will show you how you can bind Jagged array or single dimension array to the repeater control. 1) Jagged array Let’s create Jagged array first. Create repeater control on the aspx page. Bind Jagged array to

Posted in Microsoft Technology Tagged with:

Session is null in ASHX handler

I was trying to access session inside ASHX page but I was getting a null reference exception.  I think session should be available on every request but it’s not the case with ASHX handler.  I was wrong there. If you

Posted in Microsoft Technology Tagged with: ,

Add JavaScript inside Head at runtime

I was wondering how can I emit JavaScript within the <HEAD> element of ASP.NET page from code behind.  I knew that we can insert JavaScript using RegisterClientScriptBlock and RegisterStartUpScript but those method is being used to add JavaScript block within

Posted in Microsoft Technology Tagged with:

ASP.NET session expires before timeout value specified in Web.Config

Note: You can refer this article to know more about different ways to store session state. There are number of reasons why values stored in session being lost before session timeout value set in web.config. Are you using In-Proc Session

Posted in Microsoft Technology Tagged with:

IIS 404 Custom Error not working as expected

When I tried to access fake .aspx page to make sure IIS returns custom 404 error page, I saw .net specific error “The resource cannot be found”. Screenshot# 1 I was wondering why IIS custom 404 error page not being

Posted in Microsoft Technology Tagged with: ,

Page_load event fires twice with FireFox only

I came across weird behavior of Firefox 3.0.X that submits forms twice.  Let me explain what I have seen. Main.ascx has a reference of UC1.ascx Main.ascx also has a UC2.ascx control reference. When I make the request to PageX.aspx that

Posted in Microsoft Technology Tagged with: ,

Ads