-
22
May

IE 8 Profiler
Microsoft IE-8 profiler is great tool for developers. Read more about it directly from MS website.
more details..
http://msdn.microsoft.com/en-us/library/cc848895(VS.85).aspx
http://msdn.microsoft.com/en-us/library/cc848893(VS.85).aspx
noneWhen your project becomes big, deployment becomes very very painful.
If you are copying files manually from Development to Testing and from Testing to Production Server(s) its a nightmare.
I tried the setup project and it was time consuming to configure and make sure you have added all the related references for testing and production.
Finally went to good old DOS command (xCopy – suggested by Microsoft). Initially I was skeptical as it will copy the entire folder structure from development to testing or Production.
After reading more about xCopy realised it has very bunch of handy parameters which does our job exactly the way we wanted it to do.
Create A .bat file say Dev2Test.bat Click here to download file
1. @ECHO OFF
2. CLS
3. REM /S : Subdirectories
4. REM /Q : Quiet Donot display Filenames
5. REM /R : Overwrites Read Only File
6. REM /Y : Supress Prompting When Overwriting Existing File
7. REM /I : If Destination doesn’t Exist and copying more than One File, its assumed as DIRECTORY.
8. ECHO ‘Processing Local 2 Testing : Complete’
9. ECHO ‘Make sure Testing Server Directory is Mapped as Y:’
10. net use Y: \\yourserver.address
11. ECHO ‘Copying Local To Testing Directory… Please wait …….’
12. XCOPY C:\ProjectFolder Y:\ProjectFolder /S /Q /R /Y /I /EXCLUDE:ExcludeList.txt
13. ECHO ‘* * * * * * Copying Completed * * * * * * * *’
14. PAUSE
Lines 1 – 11 are self explanatory
Line 12 is the one which does the Magic
/Exclude:ExcludeList.txt Click here to download
contains all the extensions and folders which you want to exclude while copying.
One entry per line.
In my Excludelist.txt I have excluded the following files and folders.
.vb - Code
.scc - Visual Source Safe
.user - Visual Source Safe
.vspscc - Visual Source Safe
.resx - Resource
.suo - Visual Source Safe
.config - web.config file (as it could be different for each environment)
.xml - If you use GhostDoc for documentation
.sln - Solution File
.vssscc - Visual Source Safe
.pdb - Gets created along with DLL (for production you dont need this)
.myapp - Visual Studio File
.settings - Visual Studio File
\My Project - Visual Studio Folder
\obj - VS Folder
\bin - As Visual Studio creates \bin for every subproject you create, I want to exclude this too.
I also have another Batch file which copies only the main Bin folder from Development to Testing / Production.
If you use XML Files, or Config Files then separate Batch files will be useful so that things dont get messed up.
noneThis is popular question asked in many tech forums / QA pages.
Simplest way to turn Off the Right Click is
Add the atttibute onContextMenu = “return false”
Ex :
<body onContextMenu=”return false”>
Tested this on
IE 5.0 and above / Firefox 2.0 and above.
PS: This doesn’t alert users with any warning or error messages when they right click. By warning them we dont want to rub their ego to find a solution.
noneIn Asp.net 2.0 multiple connectionStrings & appSettings can be handled very easily using the attribute “configSource”
create a new xml file devAppSettings.config under a new folder myConfigsettings
<?xml version=”1.0″?>
<appSettings>
<add key=”uploadfolder” value=”C:\test\UploadDocs”/>
<add key=”domainname” value=”devdomain”/>
</appSettings>
<?xml version=”1.0″?>
<connectionStrings>
<add name=”nwind” connectionString=”Data Source=(localhost);Initial Catalog=nwind;User Id=sa;Password=sa;”
providerName=”System.Data.SqlClient” />
</connectionStrings>
<connectionStrings configSource=”myConfigsettings\devconnectionStrings.config”/>
<appSettings configSource=”myConfigsettings\devAppSettings.config” />
Similarly you can create as many config files for testing, production and change the name in Web.config
tstAppSettings.config
prdAppSettings.config
If you form has asp:Fileupload control along with other controls like dropdownlist, calendar.. you will be facing standard problem of Fileupload control losing (the file) value when users click upload first and dropdown next.
This problem can be solved by using Updatepanel. (AJAX)
Place all the controls inside updatepanel and place the FileUpload control and Upload button outside the panel.
Any autopostbacks will be handled by AJAX and Full postback will be handled by Upload button.
Example:
<asp:UpdatePanel ID=”UpdatePanel1″ runat=”server”>
<ContentTemplate>
<asp:DropDownList runat=”server” ID=”ddl” AutoPostBack=”true”> </asp:DropDownList>
<br/>
<asp:Calendar ID=”calAsOfDate” runat=”server” DayNameFormat=”Shortest”> </asp:Calendar>
</ContentTemplate>
</asp:UpdatePanel>
Fileupload placed outside the Panel
<asp:FileUpload Width=”600″ ID=”uldReport” runat=”server” /> <br/><br/>
<asp:button ID=”cmdCancel” runat=”server” UseSubmitBehavior=”false” CausesValidation=”false” Text=”Cancel” />
<asp:Button ID=”cmdUpload” runat=”server” Text=”Upload” OnClick=”cmdUpload_Click” />
Problem solved !!
5 comWe know Ctrl-C / Ctrl-V what is this Crtl – D ?
Its nothing but alternate shortcut for Delete button.
For Key Board lovers this could save some time. Without moving the right hand from mouse, you can delete the file
Eventhough Visual Studio 2005 has Menu control, I feel skmMenu is still flexible and useful.
I feel skmMenu is better than Menu control in following ways..
23 com- Image / MouseOver image handling is very easy.
- Roles are easy to assign.
- No complicated styles.
- No need to complicate Web.config settings.
- Dynamic XML Menu generation is straight forward.
Click here to for updated post on skmMenu 2.3
Visual Studio 2005 – Compile Options
.XML files are used to create Documentation.
If you need to disable them, then
Project Properties > Compile and Uncheck Generate XML Documentation file option.
noneIf you are using Update Panel and try to Export gridview contents to EXCEL or Word, your asp.net page will throw nasty error. “Sys.WebForms.PageRequestManagerParserErrorException”
Its because AJAX & Response.write don’t go together. By calling Response.Write() directly you are bypassing the normal rendering mechanism of ASP.NET controls. The bits you write are going straight out to the client without further processing (well, mostly…). This means that UpdatePanel can’t encode the data in its special format.
There are couple of ways to solve this problem.
1. Place the Export Button outside of Update Panel.
2. By Pass the Export Button using <Triggers>
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID=”cmdExport” />
</Triggers>
</asp:UpdatePanel>
if your Export button is part of UserControl then specify usercontrolid:buttonid
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID=”uscSelCtl:cmdExport” />
</Triggers>
</asp:UpdatePanel>
ASP Asp.Net Asp.net Menu asp:menu Atalasoft Browser CSV Database datatable Developer Error Error Message FF 3 firefox Freebie GoogleChrome gridview html IE IE8 Infragistics Javascript Microsoft Mp3 Remote Desktop Server skmmenu SQLServer SQL Server SQLServer 2005 sql server 2005 SQLServer 2005 Management Studio SSIS Terminal Services Tools UltraWebGrid Utf-8 VBScript Vista Visual Studio web.config Windows Wordpress XML XP
WP Cumulus Flash tag cloud by Roy Tanck requires Flash Player 9 or better.