[Ubuntu]: Still having trouble installing VMWare? Switch to VirtualBox

If you are still having trouble installing VMWare Server 2.0 on your Ubuntu box after following my instructions, then I suggest you to give up VMWare Server and switch to a very nice Open Source software called VirtualBox. Here is the description of VirtualBox from its web site: VirtualBox is a family of powerful x86 virtualization products for enterprise as well as home use. Not only is VirtualBox an extremely feature rich, high performance product […]

[Ubuntu]: How to install VMWare Server 2.0 Beta on Ubuntu 8.04

Not-so-good news: the Linux installation package of VMWare Server does not have a user-friendly graphic user interface. And very likely you will need to build the package yourself on your Linux box. It is why it is not easy or straight-forward to install VMWare Server on Ubuntu. (It’s a shame that the VMWare development team does not have a deb package for Ubuntu, or a working rpm package for Fedora Core) Download VMWare Server 2.0 […]

[WinForm] How to dynamically add a drop down list in datagridview control

Scenario: You need to dynamically add a drop down list in a DataGridView control in a WinForm. Requirements: The items of the drop down list are dynamically bound with data from database. Solution: 1. Connect to database and retrieve data into a datatable, i.e. dtRanks; 2. Create a DataGridViewCombBoxColumn, set necessary properties of the CombBox column, then add it to the GridView control: DataGridViewComboBoxColumn ranks = new DataGridViewComboBoxColumn(); ranks.DataPropertyName = “TestID”; ranks.Name = “TestID”; ranks.HeaderText […]

MS SQL Server Express Error 5123 When Attaching a Database

I have been using MS SQL Server Management Studio Express to attach and detach my database for some time and have not had any problems until today. When I tried to attach a database, MS SQL Server Management Studio Express gave me error 5123: Failed to retrieve data for this request. (Microsoft.SqlServer.Express.SmoEnum) Additional Information: … CREATE FILE encountered operating system error 32(The process cannot access the file because it is being used by another process.) […]

MSDTC on server ‘\SQLEXPRESS’ is unavailable

I am currently working on a Windows application with C# and MS SQL Server 2005 Express as the back-end database. It’s been working fine until today when it gave me an error message when I tried to update a datatable. The error message is: MSDTC on server ‘(server name)\SQLEXPRESS’ is unavailable. According to Microsoft SQL Server 2005 Express Edition with Advanced Services Readme (see section 3.4), the cause of the error is: Because the Microsoft […]

Forms Authentication in ASP.NET 2.0 without Membership Provider

The membership provider is a new feature in ASP.NET 2.0 and helps web developers quickly and easily  implement forms authentication and authorization in their web applications. But what if you can’t use the membership provider in your applications? For example, my company implements a single sign-on system for authentication (many companies have the similar single sign-on system), and the user who is accessing our web application  is redirected to the single sign-on page for authentication. […]

A week of Ubuntu

I was very frantic with Ubuntu in the past week. Why? The reason is very simple: my laptop HP zu1175 is too old to handle Windows XP, but I do not want to throw it away, so I decided to give Linux a try. Here is my old HP zu1175 laptop’s specs: CPU: Pentium III 700MHz RAM: 384 MB HD: 20 GB DVD-ROM CDRW-ROM Pretty old, right? I used to think Fedora Core would be […]

SHUTDOWN is in progress. Login failed for user ‘…’. Only administrators may connect at this time.

Today, one of my web sites went down and the application sent me an exception error message like “SHUTDOWN is in progress. Login failed for user ‘…’. Only administrators may connect at this time.” It worried me at first because I thought my web site was under some malicious attack caused the server to shut down. So I searched the Internet with the error message and it turned out that it had nothing to do […]

ConstraintException occurred when updating DataTable with TableAdapter

I have been using SqlDataAdapter and strong typed DataSet and DataTable in my projects in .NET 1.1 for quite some time and have not had any problems. Now, in .NET 2.0, SqlDataAdapter is replaced with TableAdapter, which is much easier than SqlDataAdapter to create a data access layer. When I played with it in one of my projects last week, I came across an exception error when updating a DataTable with TableAdapter. The error happens […]

System.ArgumentOutOfRangeException occurs when updating DataView object

I have been working on a project which involves sending out emails to our customers in the past week and came across a very interesting error with a DataView object. The application is required to send out batch emails once a day, so I created an email message queue table to store the outgoing email messages. After a message is sent, the column that stores the delivery status will be changed from 0 to1 so […]