Friday, August 31, 2007

Update Panels are dangerous

http://encosia.com/index.php/2007/07/11/why-aspnet-ajax-updatepanels-are-dangerous/

IsDate equivalent in C#

We need not load the entire Microsoft.VisualBasic.Information.IsDate() for this function alone...

We can use the following the basepage

public static bool IsDate(object Expression)
{
string strDate = Expression.ToString();
try
{
DateTime dt = DateTime.Parse(strDate);
if (dt != DateTime.MinValue && dt != DateTime.MaxValue)
return true;
return false;
}
catch
{
return false;
}
}

Thursday, August 30, 2007

MaskedEditExtender + Mask for MMM d, yyyy format

Mask=99/99/9999 will give makededit mask to enter mm/dd/yyyy in textbox. I have tried with LLLL 9, 9999. No improvement. Looks like there is an issue in AJAXControlToolkit..

http://forums.asp.net/t/1145071.aspx

HTTP Keep-Alives Enabled

When it is enabled, server will make strong attempt to keep the connection open between request, thus improves the performance.

http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/ea116535-8eb9-4c80-8b14-b34418dbfe42.mspx?mfr=true

AJAX History Control

http://www.asp.net/learn/ajax-videos/video-149.aspx

but this is with AJAX Futures Microsoft.Web.preview.dll - Not with AJAX Toolkit.

Wednesday, August 29, 2007

Failed to start monitoring file changes in ASP.NET 1.0

Occurs in VS.NEt 2003, .NET 1.1, ASP.NET 1.0

Resolution : Give NetworkService and ASPNET access to the folder

http://support.microsoft.com/kb/317955

Tuesday, August 28, 2007

EXECUTE permission denied on object 'sp_sdidebug', database 'master', owner 'dbo'

Resolution:

In Visual Studio 2005, Disable T-SQL debugging if you dont want to debug SQL Queries. You can check Managed Code, so you can debug the C# code.

Wednesday, August 22, 2007

Load Test Web Applications Using Visual Studio Team System

Microsoft ACT requires VS.NET 2003 to be installed. For ASP.NET 2.0 applications, you can use VS.NET 2005 Team Suite for Load Test

This is good article on load testing using VS.NET 2005 Team Suite http://www.codeplex.com/PerfTesting/Wiki/View.aspx?title=How%20To:%20Load%20Test%20Web%20Applications%20Using%20VS.NET%202005&referringTitle=Visual%20Studio%20Team%20System%202005%20Index

HTTP 403.9 - Access Forbidden: Too many users are connected

Mostly if you use Windows 2000 or XP Professional, you need to deploy your application in Windows 2003 server..

http://support.microsoft.com/kb/262635

Maximum Number of Concurrent Connections to IIS6

if the OS is Windows 2000 or XP, then maximum no of concurrent users is limited to 10

if you have Windows 2003 server, it depends on the server memory and application caching..

http://blogs.msdn.com/david.wang/archive/2006/04/12/HOWTO-Maximize-the-Number-of-Concurrent-Connections-to-IIS6.aspx

http://support.microsoft.com/kb/262635

Tuesday, August 21, 2007

Cannot find template with id testproject-v1-wordManualTest for cSharp test Project

VS.NET Team Suite - After installing, I was not able to see WebTest, LoadTest templates in the test project.

Resolution:
1. Run devenv /resetuserdata in VS.NET command prompt

2. Run devenv /installvstemplates in VS.NET command prompt

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1559338&SiteID=1

http://geekswithblogs.net/ehammersley/archive/2005/11/08/59451.aspx

Friday, August 17, 2007

Request Format is unrecognized

Enable

add name="Documentation"

in Web.Config

Limiting the Web Services Protocols

Open Web.Config

webServices
protocols
remove name="HttpPost"
remove name="HttpGet"
remove name="Documentation"
add name="HttpSoap"
/protocols
/webServices>

If you set web.config like this, it will allow only Soap protocol to access the web services. Through normal Internet Explorer, you cannot pass any parameters to the web services. Better security for production web services..

Disable WSDL File Generation for Web Services

Open Web.config

web services
protocols
remove name="Documentation"

This will disable WSDL File generation by WSDL.exe

Tuesday, August 14, 2007

Horizontal Accordian control

AJAX Accordian Control expands vertically. I have implemented horizontal expansion through CollapsiblePanel Extenders by


ExpandDirection="Horizontal" TargetControlID="leftDetail" ExpandControlID="sideHeader"
CollapsedImage="~/images/left.jpg" ExpandedImage="~/images/right_dull.jpg" CollapseControlID="leftHeader"
runat="server" Collapsed="true">

ExpandDirection="Horizontal" TargetControlID="sideDetail" ExpandControlID="leftHeader"
CollapsedImage="~/images/right.jpg" ExpandedImage="~/images/right_dull.jpg" CollapseControlID="sideHeader"
runat="server" Collapsed="false">

UpdatePanelAnimationExtender - OnUpdating always executed

As per
http://www.asp.net/AJAX/Control-Toolkit/Live/UpdatePanelAnimation/UpdatePanelAnimation.aspx

It is important to note that because of the UpdatePanel architecture, the OnUpdating animation will always play when any partial postback starts, but the OnUpdated animation will only play at the end of a partial postback if its UpdatePanel was changed (note: setting the UpdatePanel's UpdateMode="Always" will ensure the OnUpdated animation plays when every partial postback completes)

So we can't have UpdatePanelAnimationExtender for individual UpdatePanel in a page..