# Friday, June 29, 2007
    Three days ago my machine hung. I still don't know why. I had been away for a while, came back, moved the mouse... hang! Oh bummer. So, my only choice was to hard boot it. I really hate to do this, especially when I have an active development environment open and a Parallels session running. Nonetheless, it was my only option.

When I started Parallels after the reboot Windows dropped into disk check mode to make sure all systems were go; they were not. The Windows disk scan started spitting out all kinds of corrupted, orphaned, lost filenames, but after a while it said it had everything repaired and booted into the Windows desktop. After poking around a little everything appeared to be OK. Nothing lost. Nice. However, when I opened Visual Studio and tried to login to the Web Application I was working on, the login failed.

Argh! I was *just* working on this application yesterday without problems. <sigh> Something obviously went wrong on that hard reset. It took a whole day to figure out, but I finally realized that my SQL Server setup wasn't working properly. When I opened SQL Enterprise Manager, right clicked a table and selected "Display All" or "Display Top..." it would chug for a bit then pop up an error message that simply read "Unknown Error." Nice. I'd like to give a gold star to the guy that wrote that error dialog.

I tried everything I could think of to get SQL Server to work again. even replaced my virtual C drive with a back up virtual C drive from several months ago. When I did that it worked, but the back up drive was too old to utilize, so I had to revert back to the drive that was giving me troubles. However, with this new knowledge that the DB was not corrupt and SQL Server would work under the right conditions I pressed on. I twiddled the registry. I uninstalled and reinstalled SQL Server 2000 (twice). Still, nothing worked. Same error.

After much poking around on the Internet I finally came across this post. Down near the bottom Fotis Tsitsirigos writes "I had the same problem. The solution was to run the Norton Win Doctor. It found some kind of error in the registry, regarding the "msadce.dll" and fixed. Since then, everything works fine." Ah hah! So, I searched around a bit for how to "fix msadce.dll", but again, no success. Finally, I took Fotis' advice, went to Symantec and bought System Works, which includes WinDoctor.

Once I got everything installed, ran WinDoctor and let it fix the problems it ran across... Walla! SQL Server Manager is working again! Praise the Lord and Thank you Fotis Tsitsirigos!

Can't say this will work for everyone who gets the "Unkown Error" dialog, but it worked for Fotis and me!

Have a blessed day.

posted on Friday, June 29, 2007 4:43:19 PM (Central Daylight Time, UTC-05:00)  #    Comments [0]
# Tuesday, April 03, 2007
I'm a recent Mac convert, but that's a different story I'll tell another time.

What's important is that I am able to do my job, which is to write Windows software, on the Macintosh. I can do this because of an incredible application called Parallels. Parallels allows me to run Windows on my Mac, but better yet when run in Coherence mode Windows applications run seemlessly along side Mac applications as if the Mac were able to run Windows apps out of the box. It is truly an amazing thing to see.

I've been running in Coherence mode since one of the beta releases of Parallels and quite frankly have become adicted to it. I didn't realize how badly until it quit working one day. All of a sudden I started getting an error dialog in Parallels each time I would try to start it in Coherence mode.



I tried everything I could think of to get it working. I even posted a case on in the forums at Parallels to see if anyone else has had this problem. However, I got no response. So, since I had gotten so used to running in Coherence mode it just about drove me bonkers to run in "Full Screen" or "OS Window" modes. So, I kept trying to figure out what was going on.

Once day I got a core dump in Windows. You know, the BSOD, Blue Screen of Death. When that happened I took the time to investigate it a little and noticed that it was my video driver. Hmmmmm... So, as one of my last ditch efforts I tried reinstalling the Parallels Tools in Windows from the ISO image that ships with Parallels in hopes that it would reinstall the video driver and perhaps fix Coherence mode. Sure enough, after reinstalling the Parallels Tools... Walla! Coherence mode worked again! Praise the Lord! Thank you Jesus!

So, in an effort to share my joy, I wanted to post my results here in hopes that it helps someone else. Below are the steps I took to reinstall the Parallels Tools in Windows.

How to reinstall the  Parallels Tools in Windows:
  1. On the Parallels menu select Devices -> CD/DVD-ROM 1 (or whatever the CD option is on your machine) -> Connect Image
  2. Locate the file called "vmtools.iso" It should be located in the "Macintosh HD\Library\Parallels\Tools" directory.
  3. Select the "vmtools.iso" file and press the "Open" button. This should cause the Parallels Tools installer to start automatically.
  4. Follow the instructions given in the setup dialogs for Parallels Tools.
  5. When the install is complete, restart Windows.
  6. You should now be able to run in Coherence mode again.
I hope this has been helpful. Have a blessed day.

posted on Tuesday, April 03, 2007 8:19:11 AM (Central Daylight Time, UTC-05:00)  #    Comments [2]
# Friday, February 23, 2007
I don't know why, but I thought Bob Parson's was a Christian. It must have been the fact that Parsons Technology marketed QuickVerse, among other Christian software. So, when I found out a couple of years ago that GoDaddy.com was owned by Bob Parsons, I was down right excited. Not only was GoDaddy.com a top-notch company, but there was a solid man of integrity at the wheel... or so it seemed.

Not long after I transferred my first domain over to GoDaddy.com I started to suspect that my first impressions of Bob Parsons were wrong. I began to see conscious decision on GoDaddy.com's part to use women in most of their advertisments and site design. I'm ashamed to say I turned a blind eye to that and have supported GoDaddy.com for several years now with about a dozen domains that are registered there. I've even recommended the company to others, but not any more.

In an email I got today from GoDaddy.com I read about their latest TV commercials. So I clicked on the link to to see, only to hastily scramble for the close button on my browser when I realized they are completely inappropriate and defilling. DO NOT go check them out for yourself. You can get all the information you need by reading Bob's personal blog.

So, I've learned my lesson. I won't turn a blind eye any longer. I don't want any of my domains associated with an organization who blatantly promotes the filth that GoDaddy.com peddles. I'm not exactly sure where to go, but I'm looking and once I find a registrar with integrity, morals and high standards I'll gladly pay 3 times the cost if I have to to support them. So if you know of such a registrar, please let me know. I'm interested.

With that, bye, bye Bob. I'm taking my business elsewhere... and if you by chance run across this low-traffic, low-profile blog, please take the time to read this. My prayer is that reading it will truly change your life... forever.

posted on Friday, February 23, 2007 11:24:31 PM (Central Standard Time, UTC-06:00)  #    Comments [2]
# Thursday, January 11, 2007

For months I have been struggling with a very strange issue where my Internet Explorer caption bar gets filled with garbage (e.g. ??????????????????4???????) . I have not been able to find any help on the Internet so wanted to post my findings here.

The issue pops up randomly and seems to be unrelated to anything I've done recently on the machine. The symptoms are that the Caption / Title bar of Internet Explorer (IE) display garbage for every web page opened and IE crashes when I attempt to close the browser.

Today it happened again, so once again I tried to get the problem resolved. In the past I have always just gone to a System Restore point a day or so in the past and that fixed it. So, I thought it was relate to automatic updates in Windows. However, when I went to restore today I found that I did not have any system restore points, but that's a different issue related to a recent computer tragedy I had.

So, without having system restore to fall back on I had to find more clues as to what was going on. After some investigation and experimenting I discovered that removing the Google Toolbar corrected the problem. Just to confirm I reinstalled the Google Toolbar and the problem re-occurred. See the screen shots below for examples of what I'm talking about.

Before Google Toolbar:

After installing Google Toolbar:

Exception raised when trying to close IE after Google Toolbar installed:

So, since this has driven me nuts in the last 4-6 months I really wanted to get something out there that might help someone else.

Have a blessed day.

posted on Thursday, January 11, 2007 1:22:18 PM (Central Standard Time, UTC-06:00)  #    Comments [0]
# Friday, December 22, 2006

I use Windows XP for my development machine. I also work on two web applications that both want to be the default web site and will not run in a virtual directory. Therefore, I find that I’m always switching back and forth between these websites in IIS. So, today I went looking for a better solution and found this:

XP Pro IIS Admin
http://jetstat.com/iisadmin/

I’ve installed it on my machine and am pleased. To the best of my knowledge this is truly a free utility and not spyware, but I don’t know that for a fact. I hope you find it useful.

posted on Friday, December 22, 2006 9:59:16 AM (Central Standard Time, UTC-06:00)  #    Comments [1]
# Wednesday, November 22, 2006

The Journey is Its Own RewardI read a very interesting post on Brydon's blog this morning. His post addresses an aspect of business that is very near to my heart. That is: life. When I graduated from high school and began working fulltime, one of the first reality checks I had was that there are no more summer vacations. It had never really occurred to me before my first real job that once you're out of school you don't get any significant time off. The second big reality check for me was the realization that I never was "going to arrive."

What I mean is this; without consciously thinking about it, I was always working toward sometime in the future when I wouldn't have to work again. My guess is most people are that way. Some may not even realize it until it's too late, but for most of us, we’re not going to ever “arrive.” For us, the journey is it’s own reward.

I realized this one beautiful spring evening as I drove home from work. The sun was just starting to cast late afternoon shadows and the temperature was perfect. As I drove home with my windows down I passed through what is known as restaurant corridor. The smell of various foods cooking all blended together with the perfect temperature and gorgeous sunset to provide one of those perfect moments. I immediately started dreaming of how nice it was going to be when I could experience this all the time.

That's when it hit me. This was a moment, not a lifestyle. The Lord gives you moments in life that are to be treasured. Instead of always looking for that time in the future when life will be perfect, I realized that I need to treasure 30 seconds here, 5 minutes there, whenever they come.

Work is like this. Unfortunately, no matter how much you like your job, for most people it is just that; a job. Either outwardly or secretly they’re looking for that time when they can do what they really want to do.

For instance, I *love* to write code. I still sit back sometimes and think "I can't believe I get paid to do this." On the other hand, there are many days I hate what I do. It's monotonous. It's frustrating. It sucks the life right out of me. On those days I want to quite and do something else. That's why I love Brydon's article so much. It addresses this reality of work being part of life.

Everybody needs change at some time. It doesn't matter how comfortable a chair is, you've got to get up and stretch after a while. It doesn't matter how much you like to sleep, you're going to get sore after being the bed for too long. Work is the same way. No matter how much you love what you do, you just need to give your brain a break sometime and do something different.

I really hope I can create an environment for the people who work with me that is like this. Whether it is my family in our home based business or others who come to work with us; I want to be able to provide an environment that breathes life into people not suck it right out of them.

Furthermore, I want to figure out how to extend this concept to our family. Surely there is a lesson to be learned here about encouraging our children to get the most out of life while at the same time being the most productive and helpful that they can be in their daily lives.

Thanks for the article Brydon. You've motivated me.

posted on Wednesday, November 22, 2006 12:12:52 PM (Central Standard Time, UTC-06:00)  #    Comments [1]
# Monday, November 13, 2006

This evening I was going to do something very simple: bind a couple of columns in a DataRow to a Repeater control on one of my ASP.NET pages. I coded everything straight through and compiled without thinking much about it. However, to my surprise I got a runtime error when I opened the page with the control on it. Much more to my surprise the error was stating that a column the DataRow I had bound to did not exist. Problem is, the column did exist and was spelled exactly like the column being reported as an error.

DataBinder.Eval: 'System.Data.DataRow' does not contain a property with the name dtCommentDate.

I looked at the documentation for DataBinder and it looked just like mine. My code looked like this:

<asp:repeater id="_rptComments" Runat="server">
   <ItemTemplate>
      <asp:Label ID="_lblDate" Runat="server">
         <%# DataBinder.Eval(CType(Container.DataItem, System.Data.DataRow), "dtCommentDate")%>
      </asp:Label>
   </ItemTemplate>
</asp:repeater>

which matched what the documentation said exactly. So, I beat my head against a wall for an hour or so trying to figure out exactly what was wrong.

After spending much time tweaking the syntax, getting some things to work, finding most failed, I noticed something about the above error that I had not caught my eye until this point. That is the word "property." I had assumed that the DataBinder.Eval() call was attempting to bind against a column or Item or something that used the "dtCommentDate" as a key. However, this error is telling me that "dtCommentDate" is being bound directly to the DataRow object as a property accessor. With this in mind I tried one last syntactical change:

<asp:repeater id="_rptComments" Runat="server">
   <ItemTemplate>
      <asp:Label ID="_lblDate" Runat="server">
         <%# DataBinder.Eval(CType(Container.DataItem, System.Data.DataRow), "(dtCommentDate)")%>
      </asp:Label>
   </ItemTemplate>
</asp:repeater>

Notice the parenthesis that surround the dtCommentDate. Since the contents of the second parameter are directly bound to the DataItem object, in this case that means that the Item accessor syntax of the parenthesis is necessary.

In my looking around the Internet for a solution to my problem I did not find an example like this so I wanted to post it here in hopes that it will help someone else.

posted on Monday, November 13, 2006 10:31:15 PM (Central Standard Time, UTC-06:00)  #    Comments [3]
# Friday, October 27, 2006

Today I didn't bill for my time. I couldn't. I finally hit the wall on hard drive space; a problem I've been ignoring for way too long.

Don't get me wrong, I'm not completely irresponsible on this front. I do run backup software and keep an up-to-the-hour image of everything that happens on my drive each day. The problem I'm talking about has more to do with the shear volume of digital stuff we keep these days. Mail, pictures, music, documents, code, notes, recipes you name it, seems like everything we do these days is stored digitally and the delima of what to do with it all is catching up with me.

On our last trip to Canada my children averaged 1 GB pictures per week. In and of itself that's not too much data, but what do you do with years of this stuff? I'm putting the temporary solution in place today: 400 GB drives installed in a Windows 2000 machine mirrored as one drive. In theory this should give me roughly 400 GB of storage with a redundant, always up-to-date, backup. However, we lost two drives in one machine last summer due to a power surge. Hmmmm... it's on a UPS now, but... still makes we wonder. So, my plan is to add one more 400 GB external drive via USB 2.0 and back up my storage drive at least once a week. I figure that's the best I can do, at least in my price range.

However, all of this still does not solve the long term problem; it just delays it. Whether it's a year from now or five years from now we are eventually going to run out of space on this 400 GB drive. Then what? Hopefully there will be larger drives at an affordable price, but this all seems somewhat absurd, not to mention volitile.

Thus the delima: how do we cope in a digital world? What are the right solutions? What are the wrong solutions? What do we do with all this digital stuff?

posted on Friday, October 27, 2006 3:37:45 PM (Central Daylight Time, UTC-05:00)  #    Comments [0]
# Thursday, July 06, 2006

I added a new option to our web.config file today under the appConfig section. There was nothing special about this entry. It used a key / value pair where the key was a string and the value an integer. Again, nothing special. I added a comment above and closed the file.

Next I ran the debugger to test my recent changes. To my surprise I got a message box stating that the Debugger could not attach to the web server.

"Error while trying to run project: Unable to start debugging on the web server. Server side-error occurred on sending debug HTTP request.

Make sure the server is operating correctly. Verify there are no syntax errors in web.config by doing a Debug.Start without Debugging. You may also want to refer to the ASP.NET and ATL Server debugging topic in the online documentation."

(Note to self: read message boxes more carefully the first time in the future.)

Odd, I just debugged this thing a few minutes ago. Unshaken I rebooted my machine and waited; thinking that IIS had just temporarily gotten hung up. After the reboot, however, I got the following error when opening my project in Visual Studio 2003:

"The Web server reported the following error when attempting to create or open the Web project located at the following URL: 'http://localhost'. 'HTTP/1.1 500 Internal Server Error'.

<Sigh> One of those days I see.

I opened up Google and began to search for the solution. However, after poking around a bit I hadn't found anything that cured my problem. <sigh again>

At this point I started considering what changes I had made. What possibly could have effected the opening of a Visual Studio project. Ah hah! The web.config. I had changed the web.config! So, I opened up the file to look for typos. Hmmmm... nothing there. Everything looked fine. I removed my recent additions anyway, just to see if it would help.

It did! The file opened right up without error. Alright! Now to figure out what the problem was.

As it turns out the problem was part of the comment I had made for my recent configuration key. In my comment I had added multiple dashes (-----) as a separator for a example text I had added. As it turns out these dashes seem to have caused the Visual Studio project launcher to croak. Furthermore, they cause the Visual Studio compiler to be unable to function properly.

Example:
<!--
  This is an example of what *NOT* to do in a web.config file.
  
  You should not use multiple dashes like I do below.

  Example:

  --------
  Blah
  Blah

  or it will cause problems
  -->

So, the lesson here is: do not use multiple dashes (-----) in your comments for a web.config (or I'm guessing any .NET config file) or it will cause problems that are VERY difficult to track down.

posted on Thursday, July 06, 2006 4:36:25 PM (Central Daylight Time, UTC-05:00)  #    Comments [0]
# Wednesday, June 07, 2006

We write a lot of code around here. As a result we often run into strange things that seem impossible to figure out. However, over the past 18 years, I have come to realize that with very few, if any, exceptions (no pun intended) the cause of even the most complicated errors can be determined.

Yesterday one of those very odd situations arose. We have a large application that is written in VB.NET and C#. When calling one of the the web methods on a web service written in C# I found that I was getting back nothing instead of the large set of data that was expected. Upon investigation I realized that this was only happening when the code was compiled for release and that the error does not occur in debug mode. Although this is odd, it is not complete unbelievable since it is possible that something was put into the debug only portion of the code that should not have been there. However, this time, that was not the case. The same exact code was getting executed in both modes.

The exception that was occurring was: "Invalid attempt to Read when reader is closed." The code block looked something like this:


Hashtable htObjects = new Hashtable();
SqlDataReader sdrObjects =
null
;

try
{

   sdrObjects = objectRepository.GetObjects(true);

   int intObjectId = 0;
   COurObject theObject =
null
;

   if (sdrObjects != null)
   {
      
while
(sdrObjects.Read())
      {
         intObjectId = sdrObjects.GetInt32(1);
         i
f
(intObjectId != 0)
         {
            
theObject = new
COurObject();
            theObject.Load(intObjectId);

            
AddObject(theObject, htObjects);
         
}
      
}
   }
}
finally
{
   
if ((null != sdrObjects) && (false
== sdrObjects.IsClosed))
   {
      
sdrObject.Close();
   }
}


When I examined the logs I found that the SQL exception was being thrown in the loop over sdrTrades.Read(). So, I added a bunch more log entries to track exactly where things were breaking down since I could not trace things in the debugger. What I found was quite intriguing.

I discovered that if I put a log entry in the finally block that the code worked as expected; even in release mode. This is very odd considering that the actual exception was being thrown in the try block above. As I was explaining this to a friend of mine I told him that it seemed as if this were some sort of code generation error. Then it hit me: this piece of code didn't have a catch block.

So, I went back and added a catch block to the above code and walla! It worked in both debug and release mode. Furthermore, it didn't matter how much or how little error code I put in the catch block or whatever other changes I made to the code. As long as the catch block was in place the code works in both debug and release modes with out any strange errors.

I would really like to go back now and examine the IL code for both of the cases to see exactly what is going on. However, I don't have the time right now to do that because we are trying to get a product out the door. If I find the time in the future I'll post the results of that research here.

So, if you find yourself with a strange SQL exception in your C# code that only happens when you compile for release mode, you might just check to see if you are using a try / finally block without the catch. If you are, this might just be what is happening to you also.

posted on Wednesday, June 07, 2006 2:38:05 PM (Central Daylight Time, UTC-05:00)  #    Comments [1]