Brendan Enrick

Daily Software Development

Five Things you did not know about me

Like everyone else, I’ve now been tagged into this game. Steve Smith tagged me so now I will tell you five things about me that you may not know.

1. I have lived in one city my entire life. I’ve been living in Kent, Ohio since I was born, and I have yet to move elsewhere. I’ve lived in 3 homes in Kent. I am currently attending Kent State University, so am still not out of Kent. Not sure when I will leave Kent, but I doubt I will be living here for too many more years.

2. I’ve been a world traveler since I was 10 years old. This is when my family started going on trips. Though my travels have been much more extensive than most people of my age, I have not seen nearly everything I wish to in my life. I have been to Venezuela twice, most islands in the Caribbean, Mexico a few times, Canada more times than I can remember, Hawaii once, England twice, France twice, Corsica once, once to Italy, once to Spain, and I’ve probably forgotten something. Sadly I have not yet been to Germany. I wish to see much more though, and hope to see many places in Africa, Asia, and Australia.

3. I, like Steve Smith, am a gamer. As can be seen by the title of my blog I am obviously some type of a gamer. I enjoy playing Dungeons and Dragons. Yes, I am aware that it is the stereotypical nerd game. It is not the only game that I play though. I enjoy making up my own games. These games have their own worlds and own systems for play. I enjoy playing them a great deal. I also enjoy playing card games, board games, and video games. Most of my games are console games, but I also play a lot of PC games. The board games I play are classics as well as lesser known games. One of my favorites since I was a child is called Solarquest.

4. After number 3 this one becomes more obvious. I would like to eventually work in some type of game design. I think it would be great fun. I might be able to get into video game development with help from the degree in Computer Science I am about to earn from Kent State University. I know many people who would like to work on games. This semester I will be taking a class about designing and building game engines. I hope it is a fun class.

5. Most people don’t know that while I think this five things idea is kind of cool. I have this notion that I am merely propagating a chain letter farther along. I don’t know if others have gotten this same feeling, but it would seem to me that this, while interesting, at its roots is an attempt to see how far the chain lett……. the five things blog will go.

So now I must search for bloggers who have yet to list five things or be tagged. Such a cruel fate. Here is a group of people I have yet to see five things from, and whom I know little about. I apologize in advance if these people have been tagged already or do not want to play the game.

Alessandro Gallo ( Garbin )
Joydip Kanjilal
Ian Lipsky
David Walker
Mo Meng

Constant Search Engine Optimization

With the power that search engines seem to have now, it has become difficult to design anything without considering them. Anytime I am trying to find anything I check Google first, and I often use Google to search sites that have their own searches. One reason I see for this is that all sites seem to try to optimize for search engines now.

I spend a lot of my time considering how a search engine will see any piece of code I write. When a large portion of traffic is directly attributed to a search engine, one has to keep it in mind when designing pages. A lot of times I feel that I have spent more time configuring a site to show higher in search results than I have building the site.

I am just assuming that everyone has run into the same situations. We are all trying to find newer and better ways to get our sites a little higher on those search engines. I am certain I am not the only person who spends a few seconds figuring out a way to word a link so it not only makes sense to a user, but will be seen nicely by search engines. Even in blog posts I am careful about my naming now. It is quite a change from what I was doing a decade ago.

Simple CMS v0.9.61020.1 Released. Now using Microsoft AJAX.

Microsoft just released their new AJAX Libraries, so a new version of Simple CMS has now been released which uses it. I am watching for new controls especially in the AJAX Control Toolkit to add to Simple CMS in future versions. You can suggest changes for future versions of Simple CMS and also ask questions about it using the Simple CMS Forum. Let me know what you think.

I hope everyone is keeping up with all the cool features in the MS AJAX. I hope they have some awesome stuff when we get ASP.NET 3.0

My Team Server Headache

So yesterday I was able to spend a long time battling with team server. It seams that source controls likes to keep track of where your workspaces are itself. So on a computer I don’t normally work on, I logged in. I set up work spaces on that machine, because Team Server didn’t specify them for me. I needed to put the code in a public place, so I did. When I went back to my normal machine, I told the server I wanted to get latest. Wow was that a huge mistake.

Five to ten minutes, and a seemingly endless stream of error messages later, team server has moved half of all of my files to another location. It seems that it noticed from the other machine that I had moved my workspaces, so it tried to do the same on my work machine. All hell broke loose when it could not get all of the files moved correctly. As should be quite obvious, Visual Studio cannot build half projects.

The best part of this whole experience was the time it took to move EVERYTHING back to its original location so I could start working again. All I wanted was 1 updated file. Never going to move workspaces again…..

Perhaps someone knows of some cool trick to stop that from happening. If you do I would appreciate knowing as well. Thanks.

Visible Whitespace in Visual Studio

Something quite horrible happened to me today. While I was working on some of my code, I accidentally hit some keys while holding the control key down. Unfortunately for me I did not see the keys I hit. Well now instead of seeing whitespace there were this little dots. I figured there was some checkbox in Visual Studio’s options. I could not find it anywhere, but I did discover a cool hack. In the fonts section, I found it keeps font information for Visible Whitespace. By changing the font color to white, I wouldn’t have to see the dots anymore or so I thought. Whenever I highlighted one of the dots I could see it again.

Now with my frustration building, what can I say I hate dots, I began trying different keyboard shortcuts. I eventually found what turns on and off white space.

The Answer:    Control + E + S

Hopefully no one else must suffer through the horror that is visible white space.

Simple CMS New Release Version 0.9.60908.1

A newer version of Simple CMS has just been released. The only significant change to Simple CMS is that it now supports sessions. This means that if you have a masterpage you are using with Simple CMS, you may now use the Session object in that masterpage file.

How to enable Session State with HttpHandlers
This was an interesting problem, because there isn't a page object in the normal sense of file with aspx as its extension. Normally one can just add enableSessionState = true at the top of the file. In order to achieve this with HttpHandlers you will need to implement System.Web.SessionState.IRequiredSessionState or System.Web.SessionState.IReadOnlySessionState. To do this you simply add one of these as if you are inheriting from a class.

In my case I use an HttpHandlerFactory, so I specified this for the created handler, and not the factory.

Simple CMS Released

    After much anticipation, I am sure, from my zealous readers, I offer to you Simple CMS. This is a simple content management system, hence the name, which plugs into existing applications. This ASP.NET 2.0 plug-in is not meant to be a full blown application. This is for someone who has a site, and wants to easily add content to the site. With Simple CMS you can through a web interface create content for you pages, and control the addresses of these pages within your site.

    Simple CMS is currently in Beta, but support will be offered most prominently through the Simple CMS Forum, which is also where I would like people to let me know of any features they would like to see in later versions. I already know of some large changes I plan to make for future versions of Simple CMS.

    I hope you enjoy Simple CMS, and you can expect some articles to be written and posted on about how I made Simple CMS. I will probably write these as separate articles about interesting and useful topics I employed in the creation of my content management system. If you think Simple CMS is cool, you should also check out this Cache Manager on which Simple CMS is loosely based. It is a very useful little tool.

    Steve Smith did a nice release post for Simple CMS yesterday, so rather than duplicate the content I will just link to his post.

    Thanks for reading my Blog. Keep reading it and maybe you will get a free cookie, but you probably won’t.

My Review of one of AppDev's training courses

    Don’t worry. I am still around, and I have just written my review of AppDev’s Professional Training via DVD-ROM course called Microsoft® Visual C#® 2005: Developing Applications. It was a very good course, and I would recommend it to others. My review is called Review: AppDev Visual C# 2005: Developing Applications. To write the article, all I had to do was go to ASP and click on the link entitled Write for Us. From there I was able to submit a request for the article. It was accepted shortly afterwards, and I soon after started writing the article by following their set of article guidelines. For those of you who read my blog, expect to read more of my articles on ASP Alliance.

Embedded Resources not so painful anymore.

    Well after a frustrating time trying to figure out how to make embedded resources work, I finally understand. This makes everything much easier. As some of you may know I have been working on a content management tool. (This is not a full blown content management system) Since it is designed to be portable to existing ASP.NET web sites, it is just a dll file. Even though it uses a couple of images, I don’t want anyone to have to copy image files just to get the app working correctly.

    To accomplish this I decided to use embedded resources, something I had never done before. Starting out I fumbled a lot trying to figure out how to display these, bad idea. Well I started googling for a solution to my problem, and I tried doing what Microsoft said to do. Following what they said to do got me nowhere, and left me a bit more confused. The site makes many assumptions about what I all ready know. Since I did not know these things, I took some guesses. Sadly incorrect ones. I think the authors of those resources need to learn the value of a hyperlink. It would allow them to reference old material so I could learn what they assume I know.

    After reading that I had a better reference to start googling. I started looking for the GetWebResourceUrl method, and this led me to other web sites, which had some better explainations. At first I went to an article on codeproject explaining how to access embedded image resources. This was much better than the previous one I read, but I still could not get this one working right. My example didn’t quite fit with what they did, and they didn’t explain each part of the process.The problem is that even if I had incorrect code in my file, GetWebResourceUrl still returned a url that looked like it was supposed to. Again I needed to find something to get this working, or I would have to go back and start writing a lot of code I did not want to write.

    So I tried another link I found on google, and this article on Embedding Resources in ASP.NET 2.0 Assemblies explained to me very well how to get my embedded resources working. It explicitly told me where each part of code belonged It mentioned some specifics I might need that were not even part of that example. Not only that but it had more than one type of embedded resource that it accessed. If you are ever trying to use embedded resources I recommend it, but I suggest reading this article first. I may have to start reading more articled written by Mark Hines. If you are interested in this topic, I suggest reading this article as well Embedding Resources in ASP.NET 2.0 Assemblies - Part 2.

Caching made easier with a cache manager

   I recently added caching to my Content Management System. Since I am no caching expert I wanted to make sure I had created the functionality that I wanted to make. I wanted to ensure durations were as I expected, and wanted to make sure that items were cached when they should be and removed when they shouldn’t be cached anymore. I could have changed the program to debugging mode and debugged the code. I could also have added code to check and see the values of the cache object at certain times, but I found a much easier solution.

   I found that by adding this Cache Manager plug-in to my site I was able to quickly and easily check at any moment what was in the cache. All it took to add this to my site was copying this file into my bin folder, and copying a line of code into my web.config file. Since I was just using this while debugging the application there was no need to worry about the optional security on the cache manager. When I was done setting up the caching, I simply removed the dll file and the line of code from my web.config file.

   I recommend checking out that cool little plug-in if you are doing any work with caching. I plan to use that tool any time I am working with caching on any ASP.NET web site. I like things that make my job easier.