Create SQL Server Database using C#

Here is a sample from codeproject : private void CreateDatabase(DatabaseParam DBParam) {     System.Data.SqlClient.SqlConnection tmpConn;     string sqlCreateDBQuery;     tmpConn = new SqlConnection();     tmpConn.ConnectionString = “SERVER = ” + DBParam.ServerName +                          “; DATABASE = master; User ID = sa; Pwd = sa”;     sqlCreateDBQuery = ” CREATE DATABASE ”                        + DBParam.DatabaseName                        [...]

Read More » »

List enum item names using C#

Assume you have define an enum like :public enum LanguageCollection : int{    English = 0,    简体中文,    Español,    Tuurkish,    Français}Is it possible to populate all enum item to a dropdownlist control without hard code each enum name ? The answer is Yes. Here is sample code :this.menuCBLanguage.Items.Clear();for (int i = 0; i < Enum.GetNames(typeof(LanguageCollection)).Length; i++){     this.menuCBLanguage.Items.Add(Enum.GetName(typeof(LanguageCollection), [...]

Read More » »

Remove subversion (SVN) source control from a project

How to remove subversion (SVN) source control from a project ? Too easy ways: Way 1: Just simply delete all .svn folders under your project folder and all sub folders in Windows Explorer; Way 2: Create a new folder  which you can get a Non-SVN control project code later, go to your SVN controled project, [...]

Read More » »

Should I add the Visual Studio .suo and .user files to source control ?

.suo and .user file are two types of hidden user files in Visual Studio project. .suo file which is a binary file. .user file is the project user file which is a text file. You don’t need to add these 2 files to your source control (SCM) since they contain per-user settings and SUO (Solution [...]

Read More » »

What is .suo file in Visual Studio project ?

Copied explanation from Microsoft official site:Solution Files (.sln and .suo) Visual Studio uses two file types (.sln and .suo) to store settings specific to solutions. These files, known collectively as solution files, provide Solution Explorer with the information it needs to display a graphical interface for managing your files. They allow you to concentrate on [...]

Read More » »

New site after missing my old CodeEase site

The old CodeEase site was created in 2008 or 2009, but there was a serious accident , or you can say it was my fault: I forgot to renew the hosting and did not have a time to check the status, until everything gone, finally the entire site gone, I even did not backup my [...]

Read More » »

Hello world!

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

Read More » »