My thoughts regarding ASP.NET, C#, programming practices, and more...
reading
You Should Read archives
blogs I read
|
Sunday, October 31, 2004MCSD Certification Path
On May 28, 2004, I became a Microsoft Certified Professional (MCP). I am on the Microsoft Certified Solution Developer (MCSD) track (5 exams). Here are the MCSD for Microsoft .NET Certification Requirements.
The exams I have chosen to take for my MCSD certification are listed below in order of (expected) completion :
This track has the benefit of including the Microsoft Certified Applications Developer (MCAD) certification once you have completed all of the exams but Exam 70-300. Therin lies my problem. I painted myself into a bit of a corner by taking the 70-300 exam first. Now I won't get my MCAD until I finish all 5 exams, at which point I will also receive my MCSD. Doh! MCSD Study Tools
MCSD Certification Study Method I work with several people who are Microsoft Certified Professionals and one who has his MCSD. They recommended studying for the MCSD using Exam Cram books and Transcender's TranscenderCert Exam Simulations. This method has worked very well for me. Here are the steps I have take for all my exams (more or less).
On the other hand, you will be amazed at how many questions in the TranscenderCert Exams are very similar to the actual exam. Monday, October 25, 2004Server.Transfer Vs. Response.Redirect
I always seem to need a refresher on why I should be using Server.Transfer over Response.Redirect, or vice-versa. I did a quick search on Google and there is an excellent article by Karl Moore at the top of the list, titled Server.Transfer Vs. Response.Redirect.
One thing I have learned while working with Server.Transfer is that it can make debuging the asp.net application much more annoying, especially if you are using a querystring in the Server.Transfer URL parameter. You can't see what values are going in the querystring. Thursday, October 21, 2004<add assembly="*"/> Error
This error drove me nuts for the longest time. You have been unit testing your project. After your n-th time rebuilding, you call the .aspx page you are trying to test and you get an error similar to this one:
Configuration Error Parser Error Message: Access is denied: Source Error: This error drove me nuts for the longest time. I would end up closing Visual Studio .NET and restart IIS. This would usually solve the problem for a short time. Solution: To stop the Indexing Service in Windows XP you can do the following : Enjoy. Monday, October 18, 2004C# Design Patterns
I have been interested in design patterns since I first started object-oriented programming with C# when Visual Studio 2002 was first released. At the time I had an MSDN Universal subscription.
I saw C# design patterns for the first time on the Data & Object Factory website. They have authored an excellent article titled "Software Design Patterns". The first paragraph of the article is a good summary of design patterns : "Design patterns are recurring solutions to software design problems you find again and again in real-world application development. Design patterns are about design and interaction of objects, as well as providing a communication platform concerning elegant, reusable solutions to commonly encountered programming challenges." The C# design patterns article goes on to describe the Gang of Four (GoF) patterns that are considered the foundation for all other patterns. The article includes UML diagrams and best of all... design patterns in C# source code. When I first read this article it did not hold a lot of meaning for me, but now a few years later, I can finally get my head around this design patterns and see that I am using them on a daily basis. Right off I see that I am using the Abstract Factory and Builder patterns regularly. Over the next few weeks, I will be posting more information on patterns as I come upon it. This is good stuff! Wednesday, October 13, 2004Unable to start debugging on the web server
I recently installed Microsoft Visual Studio 2005 Beta and the .Net Framework 2.0 beta on my home machine. A few days later I was attempting to debug an existing client's ASP.NET application in Microsoft Visual Studio 2002, but I ran into a problem. I would hit the F5 key and an error message similar to the following would pop up:
Unable to start debugging on the web server What could this mean? I never had a problem debugging before. I tried to debug several other existing applications and all of them would compile, but none would allow me to run in debug mode by pressing the F5 key. I had to think back to what had changed recently with my system. Ding, ding, ding...I suddenly rememberd that I had a similar problem at the office when I installed Microsoft Visual Studio 2005 beta along with the .Net Framework 2.0 beta. A new ASP.NET tab was added to the virtual directory's property window in IIS. Installing the .Net Framework 2.0 defaults all of your IIS applications to the 2.0 framework setting. Simply changing the drop down back to 1.1 and clicking OK fixed my problem. I hate the simple fixes that take forever to find. Cropper v1.3
Cropper v1.3 is an excellent screen capture app written entirely in C# by Brian Scott. If you need an easy way to capture screen shots, this is for you. Best of all, it is FREE!
Download it here. Tuesday, October 12, 2004Prompting a User to Save When Leaving a Page
Scott Mitchell (one of my favorite developers) has a new article on 4GuysFromRolla.com that you will probably find helpful. He explais how you can use the onbeforeunload event available in Internet Explorer and FireFox version 0.9 to prompt a user to "Save" his/her work before leaving the current page or closing the browser window. Check it out.
Sunday, October 10, 2004Keeping a C# Console Application Command Window Open
I am writing a small app to help me debug a problem with System.Web.Mail on different web servers. The app attempts to send an e-mail using SmtpMail class and specifying the SmtpServer property. If there are any errors they get written to console.
Everything is working great, however I would like to be able to double click the created .EXE file and have the command window remain open after the mail has been sent and any errors have been written out. You can do this by opening a command window and executing the app from there. Solution: If you add the line "Console.ReadLine();" to the end of the "Main" method, the window stays open until you push the Enter key. Thursday, October 07, 2004SmtpMail Errors
I have been sending mail using the System.Web.Mail.SmtpMail class with multiple apps for some time now without any issues when I started getting the following error message:
"Could not access 'CDO.Message' object." Not a very clear error message. I googled the error message and found an excellent resource for trouble shooting the SmtpMail class, System.Web.Mail, OH MY!. The sites subtitle is "Complete FAQ for the System.Web.Mail namespace". It gave me some helpful hints. The first one being "Look at the inner exception". Once I did that, I found that the real error message was: "Unable to open Windows Socket" Once again, the above site gave another helpful hint. I tried specifying the IP address of my SMTP server, in case there was some problems resolving the name. (Yes, I can ping the SMTP server.) This fix lead to a new inner exception: "The message could not be sent to the SMTP server. The transport error code was 0x800ccc15. The server response was not available" OK, now maybe we are getting somewhere. However, when I google this message, I don't get results that are very usefull. According to Microsoft's site here is what the error code means: 0x800CCC15 SOCKET_CONNECT_ERROR Unable to open Windows Socket. That looks familiar. I finally spoke with a friend and found out that this error may have something to do with the load on the mail server and we should restart it. I didn't have time to mess with that. My friend made the following suggestion : "Don't specify and SmtpServer property." When you don't specify the SmtpServer property the SmtpMail class uses your local mail server. That worked. What a pain. Update : We discovered the real reason for this error a few days after my post. The network guys had installed a new version of McAfee VirusScan Enterprise. This software has a feature called "Access Protection" which was preventing my app from accessing the mail server. Wednesday, October 06, 2004RegExLib.com
In case you are not already familiar with this site, RegExLib.com is an excellent resource for regular expressions.
Sunday, October 03, 2004Microsoft SharePoint Portal Server 2003
One of my clients is planning on using Microsoft SharePoint Portal Server 2003 for their intranet. I have not used Microsoft SharePoint 2003 before so I am excited to get a chance to develop components for it. Microsoft calls these component "Web Parts". Here are a few SharePoint 2003 articles and sites I found helpful in understanding SharePoint 2003 "Web Parts" development.
Content copyright ©2003-2006 Tod Birdsall
Enjoy. |