Geeks With Blogs
Nat Luengnaruemitchai Geek Blog April 2005 Entries
DesignMode Problem
Well, a bunch of people have raised an issue with DesignMode property doesn't work quite well. Fabrice already suggested some workarounds which are 1. this.GetService(typeof(IDes... !=null 2. System.ComponentModel.Licen... == System.ComponentModel.Licen... 3. System.Diagnostics.Process.... == "devenv" Today, I just experienced a problem where I used method 3 to detect whether a control is in DesignMode or not. This test will fail ......

Posted On Wednesday, April 27, 2005 10:04 PM

Can't SQL Server Have Constant?

Sometimes, I have to use function to define a constant in SQL Server. However, it doesn't perform as well as just plugging in constant value in there. Why can't we just have constant value in T-SQL? Don't tell me that there is a deterministic function. Most of the time, SQL Server just keeps calling the function although it does know that the function is deterministic.

Posted On Wednesday, April 27, 2005 3:33 AM

C# IAQ #5: Why C# Doesn't Have Class Destructor?
Sometimes, I have to connect to unmanaged system in which I have to initialize something at the beginning and need to clean up at the end. In this case, instead of writing a singleton class that have a finalizer, can't I have a class destructor to do this job?

Posted On Wednesday, April 27, 2005 1:32 AM

EBay Sppof Mail
Recently, I got a bunch of e-mail from ebay saying that my credit card account has been compromised. I'd bet it is a spoof e-mail. Can any one confirm with that?

Posted On Sunday, April 24, 2005 9:26 PM

Can I Get Phd Whiile I'm Sleeping?

Posted On Friday, April 15, 2005 4:41 AM

C# IAQ #4: Why Does Not C# Compiler Provide An Ability To Set Stack Size?

Why neitherC# compiler nor the language itself (through an ability of attribute) provide a way for developers to set their own stack size?

Note: You can modify stack size manually through a utility called EditBin.exe (

Posted On Friday, April 15, 2005 4:33 AM

C# IAQ #3: Why DBNull.Vallue While null Already Exists?
Why does Microsoft introduce DBNull.Value while it can use null instead?

Posted On Friday, April 15, 2005 4:17 AM

What Happened To C# Builder
It seems like Borland quietly dropped C#Builder from its website. Does it lose in C# IDE world to VS.NET completely?

Posted On Thursday, April 14, 2005 7:18 AM

SQL Server & MSDTC Problem in Windows 2003
Yesterday, my colleague experienced a problem when trying to execute SQL statements through a linked server. The query was fine if execute alone like exec linkserver.northwind.dbo.Ge... '12/31/2004' However, when he executed it and try to insert the result into temp table insert into #ordersexec linkserver.northwind.dbo.Ge... '12/31/2004' The server just hung without doing anything furthur. He tried to kill SPID but it waited in KILL/ROLLBACK state forever. Cause: When executing SQL statements ......

Posted On Wednesday, April 13, 2005 6:55 AM

Hitachi & Breakthrough in Its Hard Disk Technology

Slashdot posted an interesting article about new hitachi harddisk technology which is well represented in this flash video (Funny). This may help MP3 to be able to store 30,000 songs instead of roughly 3,000 songs today.

Posted On Saturday, April 9, 2005 6:15 AM

Unattended Installation: VS.NET 2003

Aaron Stebner posted an updated step to perform unattended install of VS.NET 2003. Great information.

Posted On Saturday, April 9, 2005 1:04 AM

C# IAQ #2: Why Can't We Have Overload Operator Implemented As An Instance Method
Due to c# specification, overloaded operator can only be implemented as a public static function only. This is unlike C++ where it allows both instance and static operator function. Eric Gunnerson did comment once that is because of the simplicity. Because of this limitation, you cannot declare an interface or an abstract class where you can define those operators and try to perform that operation on interface or an abstract class. This especially will impact generic class. More example to come later. ......

Posted On Friday, April 8, 2005 7:24 PM

C# IAQ #1: Timezone
I would like to start asking some questions in C# + .NET in which I don't have answers yet. If you guys know the answers, please help answer that. I will try to maintain the list of answers. Thanks :) To kick off an infrequently asked question awaiting for answer, I would like to ask why .NET BCL does not offer the API to convert time from one timezone to the other time zone. You have some way to convert time from other timezone to your local timezone by using DateTime.Parse hack though ......

Posted On Friday, April 8, 2005 1:54 AM

MSN Messenger 7.0 Released :)


MSN 7.0 is gold already.

Posted On Thursday, April 7, 2005 11:42 AM

I want Chris Brumme back, too

I noticed that Brad would like to get Chris back I would like him to be back in the blogosphere as well.

Please join this effort :)


Posted On Thursday, April 7, 2005 8:09 AM

Gmail where G stands for growth
You don't really have just 1GB on GMail anymore....Take a look at what I have right now.... You are currently using 787 MB (38%) of your 2053 MB Quoted from GMail's new feature list: G is for growthStorage is an important part of email, but that doesn't mean you should have to worry about it. To celebrate our one-year birthday, we're giving everyone one more gigabyte. But why stop the party there? Our plan is to continue growing your storage beyond 2GBs by giving you more space as we are able. We ......

Posted On Sunday, April 3, 2005 10:39 AM

Copyright © Nat Luengnaruemitchai | Powered by: