private Hashtable getDataTableToHashTable(DataTable dt)
    {
        Hashtable ht = new Hashtable();

        if (dt.Rows.Count > 0)
        {
            foreach (DataColumn dc in dt.Columns)
            {
                ht[dc.ColumnName] = dt.Rows[0][dc.ColumnName];
            }
        }
        return ht;
    }

Posted by yespia.net piacom