Click here to Skip to main content
15,919,749 members
Home / Discussions / C#
   

C#

 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser11-Mar-09 12:47
mfcuser11-Mar-09 12:47 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
Adam Maras11-Mar-09 13:32
Adam Maras11-Mar-09 13:32 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser12-Mar-09 4:29
mfcuser12-Mar-09 4:29 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser12-Mar-09 5:08
mfcuser12-Mar-09 5:08 
QuestionHiding an empty Column in Gridview Pin
edcorusa11-Mar-09 11:31
edcorusa11-Mar-09 11:31 
AnswerRe: Hiding an empty Column in Gridview Pin
dataminers11-Mar-09 12:10
dataminers11-Mar-09 12:10 
GeneralRe: Hiding an empty Column in Gridview Pin
edcorusa13-Mar-09 7:51
edcorusa13-Mar-09 7:51 
GeneralRe: Hiding an empty Column in Gridview Pin
dataminers13-Mar-09 21:25
dataminers13-Mar-09 21:25 
DataTable myDt = ....(write necessary code)



DataGridView1.DataSource = SupressEmptyColumns(myDt);




private DataTable SupressEmptyColumns(DataTable dtSource)
{
System.Collections.ArrayList columnsToRemove = new System.Collections.ArrayList();

foreach(DataColumn dc in dtSource.Columns)
{
bool colEmpty = true;
foreach(DataRow dr in dtSource.Rows)
{
if (SqlConvert.ToString(dr[dc.ColumnName]) != string.Empty)
{
colEmpty = false;
}
}

if (colEmpty == true)
{
columnsToRemove.Add(dc.ColumnName);
}
}

foreach(string columnName in columnsToRemove)
{
dtSource.Columns.Remove(columnName);
}

return dtSource;
}
QuestionDelegates for instance methods across appdomains... [modified] Pin
MrBhbk11-Mar-09 8:57
MrBhbk11-Mar-09 8:57 
Generali created VSTO 2003 addin for outlook inspector. i need help in Pin
Arun Kumar A.S11-Mar-09 7:57
Arun Kumar A.S11-Mar-09 7:57 
GeneralRe: i created VSTO 2003 addin for outlook inspector. i need help in Pin
dataminers16-Mar-09 7:03
dataminers16-Mar-09 7:03 
QuestionProblem with webservice! Pin
Bryan Karlsson11-Mar-09 7:56
Bryan Karlsson11-Mar-09 7:56 
AnswerRe: Problem with webservice! Pin
J$11-Mar-09 9:37
J$11-Mar-09 9:37 
AnswerRe: Problem with webservice! Pin
Christian Graus11-Mar-09 9:37
protectorChristian Graus11-Mar-09 9:37 
GeneralRe: Problem with webservice! Pin
Bryan Karlsson11-Mar-09 12:47
Bryan Karlsson11-Mar-09 12:47 
AnswerRe: Problem with webservice! Pin
dataminers11-Mar-09 12:01
dataminers11-Mar-09 12:01 
AnswerRe: Problem with webservice! Pin
King Julien11-Mar-09 21:03
King Julien11-Mar-09 21:03 
QuestionMicrosoft Dynamics Retail Management System (RMS) Pin
info011-Mar-09 5:41
info011-Mar-09 5:41 
AnswerRe: Microsoft Dynamics Retail Management System (RMS) Pin
Le centriste11-Mar-09 7:58
Le centriste11-Mar-09 7:58 
QuestionWindows speech Pin
half-life11-Mar-09 4:54
half-life11-Mar-09 4:54 
AnswerRe: Windows speech Pin
Xmen Real 11-Mar-09 5:22
professional Xmen Real 11-Mar-09 5:22 
GeneralRe: Windows speech Pin
Nagy Vilmos11-Mar-09 5:35
professionalNagy Vilmos11-Mar-09 5:35 
GeneralRe: Windows speech Pin
Xmen Real 11-Mar-09 5:41
professional Xmen Real 11-Mar-09 5:41 
GeneralRe: Windows speech Pin
Nagy Vilmos11-Mar-09 5:51
professionalNagy Vilmos11-Mar-09 5:51 
GeneralRe: Windows speech Pin
Xmen Real 11-Mar-09 6:12
professional Xmen Real 11-Mar-09 6:12 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.