18 Jun
There are many ways to export data from SQL Server to Excel but I think the one way to do it by real simple coding is to export the data as an XML file and then opening it in Excel.
First we fill the data in a DataSet and then export that data to an XML file. Although the file is an XML one, I give it an extension of ‘.xls’ so that Excel opens it by default and then it can be saved it as the Excel format in some other sheet.
Dim con as SqlConnection
con = New SqlConnection(“Data Source=SERVER; Initial Catalog=dbTest;uid=sa;pwd=123″)
Dim cmd As SqlCommand = New SqlCommand
con.Open()
cmd.CommandText = “spExportData”
cmd.CommandType = CommandType.StoredProcedurecmd.Connection = con
Dim ds As New DataSet
Dim da As New SqlDataAdapter
da.SelectCommand = cmd
da.Fill(ds)
Dim savefileName As String = Application.StartupPath & “\ExportedFile.xls”
ds.WriteXml(savefileName)
con.Close()
cmd.Dispose()
da.Dispose()
8 Jun
If in a table, some columns occasionally contain null values, then while trying to retrieve the values, the following error is shown:
Conversion from type ‘DBNull’ to type ‘String’ is not valid.
To solve this problem, we can check if the Datareader has a null value for the column, and if yes, then just getting the TextBox to show an empty string.
If DBNull.Value.Equals(dataReader1(“Column_Name”)) Then
TextBox.Text = “”
Else
TextBox.Text = dataReader1(“Column_Name”)
End If
28 May
Jack D. Herrington (a senior software engineer with more than 20 years of experience) writes in detail on how to build a chat system on a web application using Ajax, XML and PHP.
4 Apr
Stanford University has made available its iPhone Application Programming course for this year on iTunes U as biweekly video podcasts and slides in pdf format.
It’s not everyday that you get a chance to be taught by two Apple engineers from Stanford University.
31 Mar
Here is another excellent course from iTunes U video podcasts, for students wishing to learn Object Oriented Programming. Provided by Andrew Cain of Swinburne University of Technology.
1 Feb
Yuki Sonoda yesterday announced the release of Ruby 1.9.1. Here is a list of user visible feature changes made.
13 Jan
Sans.org has published a list of top 25 most dangerous programming errors. These errors have been compiled by a team of US and other international anti-cybercrime organizations. Two of these erors lead to more than 1.5 million security breaches during 2008.
3 Jan
Introduction to Ruby for Mac OS X : The Principle of Least Surprise by Jim Menard
1 Jan
This course is from The University of New South Wales, Sydney Australia, and is the complete video recording of lectures in progress. It is free to download to everyone everywhere regardless of whether you have an iTunes store account or not. I have gone through 25 out of 46 available lectures till now and I find it really excellent with the tutor keeping the students very interested in the stuff being taught while maintaining a real interactive note throughout. The image below describes the course in full.
Click on the image to view it in full size.
18 Nov
An article from InfoWorld, not just blatant fanboyism but an analysis supported by solid ground. Read “Why developers prefer Macs“.

| M | T | W | T | F | S | S |
|---|---|---|---|---|---|---|
| « Aug | ||||||
| 1 | 2 | 3 | 4 | 5 | ||
| 6 | 7 | 8 | 9 | 10 | 11 | 12 |
| 13 | 14 | 15 | 16 | 17 | 18 | 19 |
| 20 | 21 | 22 | 23 | 24 | 25 | 26 |
| 27 | 28 | 29 | 30 | 31 | ||
