2007
170 articles published in 2007
-
Examples on new BlogEngine.NET 1.3 features
Demos of some new features in BlogEngine.NET 1.3
-
Christmas present - BlogEngine.NET 1.3 released
BlogEngine.NET 1.3 has just been released. This is a list of new features
-
Choosing the right URL structure
I've changed the URL structure in BlogEngine.NET 1.3
-
A state aware generic list
How to keep track on the generic List<T> and if it's changed or not
-
3-tier web applications
The premise for the 3-tier web application is wrong
-
Has privacy limited our possibilities?
Big Web 2.0 API's are restricting the amount of information for developers
-
Create your own spam filter extensions
My last post about comment spam fighting resulted in a lot of e-mails from readers asking how to create their own spam fighting logic in BlogEngine.NET 1.3. So I decided to show a simple extension that listens for...
-
Fighting spam attacks
Using the 404 HTTP status header to fight of spam attacks
-
Use the provider model in ASP.NET 2.0
Get starting using the provider model of ASP.NET
-
Code samples on display
I've decided to gather the most popular code samples on a single page.
-
Make your blog talk
How to automatically and free have offer a narrated version of your blog.
-
Protect your links from Visio
Visio's sitemap feature can be dangerous if you are not prepared for it.
-
Website architecture is backwards
Any application ever build have an architect designing it. That architect could be a software architect, lead developer or just a regular code monkey and probably all of them at some point or the other. The point is that...
-
Show IIS process information
An aspx page that shows the IIS process information for debugging purposes
-
Keeping web services simple
Create custom cross platform web services that can use both POST and GET.
-
Copenhagen geek dinner update 2
Latest info on the November 2007 Copenhagen geek dinner
-
BBCode extension for BlogEngine.NET 1.2
Add a BBCode parser to your comments and/or posts in BlogEngine.NET
-
Dangers of the new ASP.NET MVC framework
Will the MVC framework divide developers and create a dual ASP.NET community?
-
First Facebook application
My first Facebook application build for users of ZYB
-
Supporting mobile devices
How to detect mobile devices in ASP.NET
-
Geek dinner Copenhagen update 1
Update on the November 2007 geek dinner in Copenhagen.
-
New FxCop 1.36 beta 2 released
FxCop 1.36 has some new rules that rocks
-
Old school AJAX call that just works
An old school AJAX call using the JavaScript Image object
-
Remove whitespace from your pages
Ok, this is not new. I’ve also written about this a few times in the past . The thing is that removing whitespace is a very tricky discipline that is different from site to site. At least that was what I thought until...
-
Remove generated JavaScript from your pages
Clean up your HTML by removing auto-generated JavaScript in ASP.NET
-
The expando attribute
How to use the RegisterExpandoAttribute method in ASP.NET 2.0
-
Copenhagen geek dinner
Let's start a Copenhagen geek dinner tradition
-
Re-enable request validation in ASP.NET
Enable HTML input without disabling request validation in ASP.NET
-
Tag mapping in ASP.NET
Shows how to use tag mapping to convert server controls to other types at compile time
-
New BlogEngine.NET videos
New videos about BlogEngine.NET are released
-
Combine multiple stylesheets at runtime
I often use multiple stylesheets in a single website to keep things nicely separated. The only problem is that the client has to make multiple HTTP requests to get them all. Today, I thought it was about time I did...
-
URL parameter injections
SQL injection attacks are performed on this site on a daily basis. Scary...
-
Making screencasts
Windows Media Encoder is good. Windows Movie Maker is not.
-
BlogEngine.NET 1.2 is released
The release announcement of BlogEngine.NET 1.2
-
New events in BlogEngine.NET 1.2
A list of all the events exposed by BlogEngine.NET 1.2
-
Evolution of code lines
Code metrics for all the releases of BlogEngine.NET
-
Translators for next version of BlogEngine.NET needed
Please help us translate the next version of BlogEngine.NET
-
Remove default HTTP modules in ASP.NET
Remove the unused HttpModules that is default in ASP.NET
-
URL rewrites and the HtmlForm action attribute
A custom HtmlForm that renders the action attribute correct for use with URL rewriting
-
Worst spam day so far
I've never recieved as much spam as I did today. Comment, trackback and referrer spam.
-
Load user controls from an HttpHandler in ASP.NET
A way to load a user control from an HttpHandler (.ashx) using reflection
-
HTTP compression of WebResource.axd and pages in ASP.NET
A HttpModule for compressing .aspx pages and the WebResource.axd handler in ASP.NET using C#
-
Resolve and shorten URLs in C#
Shows how to auto resolve URLs in a text string, turn them into hyperlinks and shorten the anchor text
-
New search feature
The new search feature of BlogEngine.NET 1.2 is demonstrated
-
Cookies and Unicode characters
Remember to URL encode your cookie values for Unicode support
-
I’m ashamed – very ashamed
I just got my first computer virus. Ohh the shame...
-
User control injection in BlogEngine.NET 1.2
Shows how to inject user controls directly into a blog post
-
Navigational header links
How to improve a website's accessibility by using header links
-
New job – going mobile
I'm starting a new job as a senior ASP.NET developer at Zyb
-
Code quality sessions
Describes the steps to take just before a release to ensure code quality
-
Running FxCop and the quirks
Using FxCop can bring pain if you don't know the quirks and what to ignore
-
Time zone trouble
How to play safe when dealing with time zones.
-
Prepare for growing projects
These are a small collection of the typical pitfalls I’ve experienced myself over the years developing ASP.NET applications.
-
BlogEngine.NET goes mainstream
BlogEngine.NET just got accepted to be a starter kit on the www.asp.net website
-
Invalid postback or callback argument
Shows that the exception is something to be happy to get. It means you're fighting spam.
-
YSlow performance challenge
I've been optimizing my blog using YSlow and now I challenge Simone to do the same.
-
Ping using XML-RPC in ASP.NET
Shows a class that can ping various services using RPC-XML
-
Cool projects that don’t exist
A list of three components for ASP.NET I would like that someone would write.
-
Make your ASP.NET application extendable
Shows how to make an ASP.NET application extendable
-
Secure your forms in ASP.NET
Do we really need CAPTCHA's to prevent robots posting to our web forms? Not if you run ASP.NET 2.0. Whether you use a form for member logins, blog comments or a web shop you want to keep it as secure and tamper proof as...
-
New extension model in BlogEngine.NET
Shows how to utilize the new extension model of BlogEngine.NET
-
Principles of simplicity
A list of 10 principles of simplicity
-
Trackback spam fighting
A short listing of the principles of trackback spam fighting.
-
Webcast on building BlogEngine.NET themes
Earlier today, Al Nyveldt aired a webcast on how to make BlogEngine.NET themes . It really shows how you can leverage all the power of ASP.NET in your themes. He uses code-behind files to dynamically change the output of...
-
Beware of the FileInfo.OpenText() method
Don't use FileInfo.OpenText().ReadToEnd() because it doesn't release the file handle
-
Release of BlogEngine.NET 1.1
BlogEngine.NET 1.1 is being officially released to the public
-
Localizing ASP.NET - which is best?
Is it ok to use local resource files?
-
Generate links to your blog
A trick to get more people linking to your blog
-
Hidden feature of BlogEngine – conversions
Shows you how to take advantage of 2 JavaScript events in BlogEngine.NET
-
Testing your code – follow up
I’ve received quite a few e-mails about my last post about unit testing and have followed some reactions around the blogosphere as well. There seem to be common believe that I don’t like unit testing or advice against...
-
Testing your code
How and when I unit test an application or class library
-
Heading off – be right back
Heading of to Italy on vacation.
-
Remove the X-AspNet-Version header
Shows how to remove the X-AspNet-Version HTTP header by changing only the web.config
-
Don’t use the ThreadPool in ASP.NET
Why the threadpool is a bad choice for ASP.NET applications and what to do instead.
-
Implement micro formats on your website
Shows how to implement a range of different micro formats to your own website.
-
Think twice before using any third-party assemblies
Why BlogEngine.NET doesn't use any third-party libraries or components
-
Comment the class before coding it
Turn your small home project into well architected pieces and save time.
-
What became of VB.NET?
I wonder where all the VB.NET code example sites went.
-
What type of developer are you?
I took a test showing what type of developer I am. Take the test here.
-
Life without TV – is it possible?
Talking about my decision to give up my TV to releave stress
-
Impersonation across threads in ASP.NET
Shows how to pass the impersonation along to the a new thread.
-
Optimize HTTP requests and web service calls
Shows how to raise the connection limit in ASP.NET
-
Section 508 and WAI triple A accessibility
The story of how I validated my blog
-
Bind countries from CultureInfo class in C#
Shows how to bind countries to a dropdown list without any XML file or database table
-
Best developer video of the year
Douglas Crockford speaks of code quality. A must-see video for all developers.
-
Google Sitemap and BlogEngine.NET
Explains how to take advantage of the Google Sitemap generated automatically by BlogEngine.NET
-
Official release of BlogEngine.NET 1.0
The official release of BlogEngine.NET 1.0 is announced
-
Print Visual Studio project
Things that the users would expect to find in an application should always be there.
-
URL parameters in ClickOnce applications
Shows in two simple steps to enable query strings in ClickOnce applications
-
Worst regular expression ever
Warning! This is the worst regex ever made
-
See who calls any method in C#
A public method that returns the caller of any method in the stack
-
Web Application Projects vs. Web Site Projects
When Visual Studio 2005 was released together with ASP.NET 2.0, the web project model was totally changed from the ASP.NET 1.x model. It took some time for me to get used to it, and in the beginning I didn’t like it...
-
Validate a form before submitting it in ASP.NET
Shows how to run ASP.NET validators client-side without hitting the submit button
-
Debug JavaScript in Visual Studio 2005
Explains how to enable debugging of JavaScript in Visual Studio
-
Measure the success of your website
Define conversion points in order to measure the success of your website
-
BlogEngine.NET update
A lot of new features have been implemented so far and some are still to come.
-
A cool new search engine for finding .NET content
Try out the new .NET search engine for better search results.
-
Microsoft stole my idea
Did Microsoft steal my idea of using Word as an editor for writing blog posts?
-
The API of a blog
Al Nyveldt just implemented the MetaWeblog API into BlogEngine.NET and wonders what people will use it for
-
Simplicity or not at all
Simplicity can be applied to all sorts of problems no matter how complex they are.
-
New bits finally available
CodePlex is finally up and running again, so daily builds can continue.
-
Status on BlogEngine.NET
Covers the status of the BlogEngine.NET project and describes what features have been added.
-
The use of audio on a website
The use of audio files can create a more loyal visitor base and help support your website's message.
-
New AJAX features
BlogEngine.NET just got new cool AJAX features using ASP.NET's client-callbacks feature.
-
Have .NET developers finally grown up?
The .NET community finally stepped up and ended the ongoing stupid debates.
-
New sitemap features in robots.txt
Describes how to enable your sitemap for autodiscovery by all search engines
-
New provider model for BlogEngine
Getting you started building a custom data provider for BlogEngine.NET
-
Send the right error codes in ASP.NET
The mothod removes the yellow screen of death and let’s the browser decide what to display to the visitor.
-
BlogEngine.NET on CodePlex
Today I finally released the entire source code on CodePlex. From there you can submit bugs and download the latest builds.
-
Events in the file and image handlers
Explanation of the events fired when an image or file is served to the client in BlogEngine.NET
-
New interim release
BlogEngine.NET 1.01 has been released. The releases fixes a series of bugs and adds new features.
-
The launch of BlogEngine.NET
After a lot of hard work I am very please to present the BlogEngine.NET for anyone to download and use. The blog engine is for anyone, but designed specifically to .NET developers that like to push software further than...
-
Getting started with BlogEngine.NET
Getting started using BlogEngine.NET - the new ASP.NET 2.0 blog engine for developers.
-
Identify external links in JavaScript
Add a class to all external or off-site links using JavaScript
-
The new blog engine - sneak peak
Forteen days have passed since I started working on the new blog engine and on this day the first working example is online. Check out the first post on the new blog. It still needs a good name so in the mean while, I'll...
-
The first post on the new blog
Marks the birth of a new ASP.NET blog engine for developers
-
Adding search capabilities to the new blog engine
The in-site search feature has been under development for a few days by Claus Christensen . Claus has been developing his own search engine for the last couple of years, so he knows a lot about search algorithms and...
-
More info on the new blog engine
The new blog engine is well on its way and almost ready for its beta test. We’ve added extra features that weren’t on our original feature list . The features include: Pingback and trackback support - Almost done Pings...
-
Implement Gravatar icons in ASP.NET
Gravatar icons can be used on all websites that lets users write comments. It could be in a forum or on a blog. The image is retrieved from the Gravatar website and is based on the e-mail address of the person that makes...
-
New blog engine in town
For more than a year, I've been blogging on the excellent dasBlog engine and it has been good. I really like the fact that it runs on XML instead of a database. However, it is written in ASP.NET 1.1 and is quite...
-
A shorter and URL friendly GUID
As a follow-up on my post from yesterday about generating shorter GUIDs , I’ve created a small helper class in C#. The class encodes a GUID into a 22 character long string and decodes the string back to the original GUID...
-
Generate unique strings and numbers in C#
The System.Guid is used whenever we need to generate a unique key, but it is very long. That’s in many cases not an issue, but in a web scenario where it is part of the URL we need to use its string representation which...
-
Psychological variables and properties
I’ve noticed that there are two different ways developers locate private variables used by properties. One way is to locate the private variable next to the property that returns them and all other private variable...
-
Asynchronous GridView in 5 simple steps
A web page with a data bound GridView control can take a long time to load. The page is not rendered until all the controls are, and the GridView cannot render before data has been retrieved from the database. So, let’s...
-
Compress and decompress strings in C#
A couple of days ago, I had to store some very big strings in an XML file. To keep the file size down I wanted to compress the strings using a GZipStream and then decompress them later when needed. I modified the methods...
-
A dynamic blogroll for ASP.NET
The blogroll has become a standard element on most blogs today. If it is an ASP.NET blog, the blogroll probably contains links to other ASP.NET blogs and that gives the visitor an opportunity to surf to other related...
-
Is security harmful for innovation?
Some of my friends have been considering moving to Vista and have therefore asked me if it’s worth the money. My answer is an unconditionally yes, but then they ask why that is and what features are worth the upgrade?...
-
Count clicks on external links in ASP.NET
On a small test website I’m building in my spare time, I wanted a way to count the number of clicks to the outgoing links from that site. Imaging hosting banners or other affiliate links where you get paid per click, it...
-
Installing Vista on my work PC
Finally I had the chance to install Vista on my work PC - something I've wanted to do since November when it became available on MSDN. Now the installation is over and it went incredibly smooth. It installed all my...
-
Generic plug-in application in C#
At work, we are about to build a new internal tool for administration of different systems. We developers need certain applications and the sales department needs some other ones. All the different people need to be able...
-
Serialize files to base64 strings
Today, I needed to store images in XML files so I had to serialize an image file into text so it could be written in the XML file. Of course, it should also be deserialized back to an image again by reading from the XML...
-
Create reusable user controls in ASP.NET
In almost every web project of any size, you would probably use a lot of user controls to separate the content and UI logic. Many of the user controls are used only at one place in the solution while others are used by...
-
A simpler AJAX implementation in ASP.NET
A week ago I wrote about the native client callback feature of ASP.NET 2.0 and why it isn’t always the smart choice. That post got me some good feedback that inspired me to build a custom callback implementation so you...
-
The true selling point of XHTML
Some years ago there was a lot of fuzz about the importance of the W3C XHTML standard. I’ve always been a firm believer of the standards and built every website to comply with them. But why? Very brief history The...
-
HttpModule to block external referrers in ASP.NET
I was ones faced with the issue of enforcing copyright on different files on a website. That meant that images and dynamically created XML files had to be blocked if accessed from outside the website. So, I had to find a...
-
Turn on true tabbed browsing in IE7
Finally Internet Explorer caught up with the rest of the browsers and introduced tabs. For some reason I don’t know, the tabs feature doesn’t work the way you would expect from your experience with Firefox, Opera etc...
-
Screen scraping in C#
Some say that screen scraping is a lost art because it is no longer an advanced discipline. That may be right, but there are different ways of doing it. Here are some different ways that all are perfectly acceptable, but...
-
Is ASP.NET too easy?
Some time ago, I wrote a post called “ Is ASP.NET too difficult? ” and I strongly believe that it is. Yet at the same time it cause problems by making it too easy to do relative advanced programming. It doesn’t seem to...
-
Beware of Client Callbacks in ASP.NET
The built-in AJAX feature of ASP.NET 2.0, also known as Client Callback, is simple to utilize but a beauty in disguise. I’m not talking about the “Atlas” toolkit for ASP.NET but the ICallbackEventHandler interface that...
-
Simple RSS reader class in C#
Update February 11th . The class now updates every feed in the cache asynchronously and automatically. On the login screen of Headlight , we are soon adding news updates so that our customers can see what is going on...
-
When to assembly
Over the years, I’ve used a lot of third-party components and self built control libraries. It an easy way to add functionality to your code projects – just reference the dll file and that’s it. This encapsulated...
-
Follow-up
Yesterday, I received a lot of mails and comments on how to improve this blog. Thank you. Most of the comments and mails I received asked me to make it easier to navigate to the different code samples on this site. To...
-
Download tools and C# source code
Here is a list of the different tools I've developed and posted to this website. Source code in C# is included for all tools. The links points to the blog post, so you can get explanations and examples on how to use...
-
One year anniversary
Exactly one year ago this website saw the light of day and in that time the archive has grown to 201 posts about C#, ASP.NET and a little bit of other related stuff. This will continue in the year to come. Because I’m in...
-
Remove the www subdomain from your website
Many websites have two points of entry for each individual page – one with www and one without. It means that if other websites link to yours, they might link to the same page using two different addresses. If you make...
-
Search Engine Positioner
After I wrote about how to check a website's position at the Google search result page, I thought it would be fun to write a little application that uses that method, but extend it to work with Yahoo and AltaVista as...
-
A state aware generic collection in C#
One of the biggest problems with the different types of collections in the .NET Framework, is that they don’t tell you if the collection as been changed or not. If you have a Collection<int> that has to be persisted to a...
-
Get your Google search position in C#
If you want to test your position in Google for a certain search term, you can do so by using the Google website. By position I don't mean Page Rank, but the actual place in the search results. You can also use C# to...
-
Stock quote class in C#
A couple of months ago one of my readers asked me to build a stock quote class that would automatically update the quote. I forgot about it, but then I found the e-mail and decided to give it a go. I started looking for...
-
Universal data type checker
In many different scenarios we need to check if a string can be converted into an integer e.g. This could be when we work with query strings and need to check if they match a certain data type. In VB.NET you can use the...
-
Working with query strings
In many cases we write our ASP.NET logic around query strings in order to show the right product page or what not. The first thing we do is to check if the query string exists in the first place before we start using it...
-
Access client information server-side
Today, I was playing around with HTTP request headers and for some reason started thinking about how limited information they provide about the requesting browser. All they really provide is the user agent string which...
-
The death of the ArrayList
In the good old .NET 1.x days where Generics wasn’t born yet, the ArrayList was the class to use for just about any type of collection. It was much easier to use compared to an array of objects and it did the job very...
-
HttpModule for query string encryption
URL parameters or query strings are often used to carry information that can be used by hackers to do identity theft or other unpleasant things. Consider the URL example.com/?user=123&account=456 and then imaging what a...
-
Do postbacks with parameters in JavaScript
Whenever you use a Button or LinkButton it is because you want to be able to do a postback when it is clicked. The same could be the case for CheckBox or DropDownList etc. but then you need to set the AutoPostback...
-
Keep the content-type in sync
Most websites include a meta-tag that tells the browser what content-type the document is. It looks like this: < meta http-equiv ="Content-Type" content ="text/html; charset=iso-8859-1" />> All ASP.NET web applications...
-
The what, why and how of XML code comments
During the years I’ve seen a lot of different ways of commenting code – some good and some bad. My personal favourite way of commenting code is by using the XML comment feature of C# and VB.NET, but the important part of...
-
The example domain
I always use google.com in my code samples as a way to show an example domain or URL. That’s because I wasn’t aware that there is a dedicated domain for use in samples which is'n available for registration. Check out...
-
Choose a standard number format
Today, I ran into an issue regarding the way numbers are parsed in different cultures, which resulted in very wrong numbers. The problem begins when your web application is set to automatically resolve the culture...
-
Get the query string right
Today, I ran into a strange little issue regarding the System.Uri class that took me too long to figure out. The Uri class has a property called Query that, according to the documentation, returns everything from the "?"...
-
The class you didn’t know existed
…Or at least a class I didn’t know existed, but let’s see if I’m right or not. The class resides in the System.Web.UI namespace and is used various places in ASP.NET. Among those places are the inner workings of the...
-
Block DoS attacks easily in ASP.NET
Denial of Service (DoS) attacks are becoming a more and more common way to bring websites and servers down. They are very easy to do and pretty hard to protect against, which is why they are so popular. The only thing...
-
Use the thread pool in ASP.NET
The thread pool gives you an easy and safe way for creating multithreaded applications, and even though the stateless nature of the Internet isn’t the best place for multithreading, it can still be the right thing to do...
-
TraceWorks is hiring
This is great news for all .NET developers who want a job in Copenhagen, Denmark. We need to find a Senior C# Back-end Developer and a ASP.NET Front-end Developer. Both positions are highly technical and very interesting...
-
Block IP addresses from your website
Recently, one of my readers asked me how to block certain IP addresses from accessing his ASP.NET website. It was a good question that could be answered in multiple correct ways. My answer was a plug ‘n play HttpModule...
-
Catch the right closing event
Whenever a Windows Form is closed, you can catch this event by overriding the OnClosing() method. In this method you have the option to do some cleanup before it closes. You can also prevent the Form from closing by...
-
Website monitoring tool
For quite a while now, I have needed a simple website monitoring tool that would check the uptime of my websites. There are a lot of different ones on the Internet, some are free and some are very expensive. All the ones...
-
Parse controls dynamically in ASP.NET
Most of the primitive types in the CLR have a Parse method that takes a string and parses it into its own data type. I could be DateTime.Parse(string) or Int.Parse(string) etc. It’s a great way of doing late binding and...
-
The Create GUID menu item is back
The Visual Studio 2005 launch improved so many things from older versions – some big and some small. Yet somehow it is always the small things you remember. The 2005 release is superior in almost any aspect except one –...
-
Use JavaScript to cancel Adobe Flash requests
Internet Explorer can only make 2 connections at a time, which means that only two elements can be loaded while the rest is queued up. Imaging a web page with 10 Flash movies, then only two of the movies can be loaded at...