On a lot of my websites, I find it very useful to know exactly what version I’m working with. Not only the version number, but also whether or not it’s running in RELEASE or DEBUG mode.
To accomplish this, it’s a fairly simple process. Just put a Label control on your webform and then set the text property of it. Here’s some sample code.
When someone enters an email address, how do we check to make sure it’s legit? Not legit as in “is it really their email address”, but as in “does it follow the rules to make it a real email address”?
For example, if someone enters “jdshfjsdhf”, that’s not legit. However, “email@example.com” is. Recently, I ran into a problem where my scheme for validating email addresses was failing me. Read more
I’m working on an MVC Website. In development in Visual Studio, things are working perfectly. My app needs to run in IIS. Easy enough, right? Just set it up in IIS and you’re off and running.
Recently though, my IIS instance of the site stopped working. What?! I began to get the following error:
HTTP Error 503. The service is unavailable.
Wha wha wha?! I checked IIS and it’s running properly. What the heck? SQL Server is okay. The thing works perfectly in Visual Studio. ARG. Read more
Session state is a funny thing. It works really well. But if users don’t stay active, they’ll lose their session. That can make for some really strange problems if session isn’t used immediately. Of course session can be checked for, but that’s a hassle. It would be easier to simply log users out before their session expires. Read more
Do you need to decrypt an app.config file? There are lots of directions explaining the process if you’re dealing with a web application, but if you’re dealing with a windows app or a service of some sort, you don’t have a web.config… all you have is an app.config. The process isn’t all that different.
Here’s what an encrypted app.config “appSettings” section might look like. Read more
Recently, I’ve been working on a project that relies on a backend business object layer. The business object (BO) layer, requires authentication in order to be used. For most of the systems, this is okay, but my project is to be used by end users. We don’t need to authenticate the users… we need to authenticate the system.
This is easy enough using the CustomPrincipal object in Rocky Lhotka’s CSLA framework (which is also being used). We simply create the CustomPrincipal and add that to the ApplicationContext. Read more
We’re approaching delivery of the baby! In the next few months, we’ll be releasing our product. This is great news as it’s been a long time coming. As is the norm, we’ve been developing our product in Debug mode. While in Debug mode, Visual Studio will generate extra files to allow stepping through the code. This is a great thing for creating the initial code, but it’s not necessary for code that’s deployed to the world at large.
When I switched Visual Studio over from Debug mode to Release mode, I got a weird error. Read more
Recently, we’ve had some fairly serious problems on our network. This has led to the admin staff removing our network profiles. It was an accident, but it still happend. The problem is now that the entire IT staff has to reconfigure our workstations.
We’re using Visual Studio 2008 for our web applications. I finally got my code base updated via Subversion (no small feat) and tried to open a solution. I was presented with an error message stating:
It appears this is caused by IIS not being installed or properly configured. Since my network profile had to be rebuilt my rights need to be reset also. They didn’t make me an administrator of my box so I can’t check it.
Wow… I’m just watching this video about how the Model/View/Controller design pattern is going to be implemented in ASP.Net and VB.Net. As many of you know, I enjoy working on and with Ruby on Rails. RoR is entirely based on the MVC design pattern. It’s surprising to me just how similar the ASP.Net implementation of it is.
Considering the benefits of MVC, it’s surprising that Microsoft hasn’t implemented it so rigorously before. Nonetheless, I’m glad to see that they will finally be releasing it. As to the title of the post, the MVC architecture makes a LOT of sense in terms of the web. When we look at the market penetration of VB.Net and ASP.Net versus RoR, it’s clear who the winner is. We, the developers, are!
I don’t really think that Microsoft implementing MVC poses any real threat to RoR. In fact, Ruby on Rails may actually benefit from more people knowing about and being comfortable with it.
Wow… I just removed log4net from my project. What a performance hog log4net is!
Let’s be clear… I had simply disabled log4net by turning the responders “OFF”. I never modified the code to check to see if debugging was enabled or anything like that. Just turning it “OFF” didn’t really help anything. I kept finding errors in the log that it was unable to get access to the log file like it wanted.
By commenting everything out, my performance jumped! I suppose at some point I’ll go back and add the logic to only log things if it’s turned on. Right now, I don’t need the logging so I’ll leave it disabled.