Click here to Skip to main content
15,912,756 members
Home / Discussions / C#
   

C#

 
AnswerRe: How to get combobox selected value on next page Pin
Sun Rays20-Nov-07 21:19
Sun Rays20-Nov-07 21:19 
QuestionSplitter Panel Resize Pin
Jeffrey Walton20-Nov-07 20:30
Jeffrey Walton20-Nov-07 20:30 
Questionhow to retrieve value from port Pin
sivaramireddy p20-Nov-07 20:01
sivaramireddy p20-Nov-07 20:01 
AnswerRe: how to retrieve value from port Pin
Michael Sync20-Nov-07 20:14
Michael Sync20-Nov-07 20:14 
Questionfolder and files Pin
RajeevKumarSharma20-Nov-07 19:54
RajeevKumarSharma20-Nov-07 19:54 
AnswerRe: folder and files Pin
Michael Sync20-Nov-07 20:17
Michael Sync20-Nov-07 20:17 
GeneralRe: folder and files Pin
Michael Sync21-Nov-07 18:52
Michael Sync21-Nov-07 18:52 
QuestionHelp with export Pin
MumbleB20-Nov-07 19:42
MumbleB20-Nov-07 19:42 
Hi Guys. I am writing a piece of code to extract data from an Access DB into a CSV file. Now, i want to inlcude int he below piece of code only records that are set to a certain value in a column. I.e. I want to extract only the records in the "EXPORTED" Column that have a value of 0. How do I do this in the below code? I think I masy have to add this in the foreach line but I am not sure how to do this. Can somebody please help me with this? I.e. I want to say,

foreach (DataRow dr in dt.Rows WHERE ["Exported"] == 0).

I am sure this is incorrect. How do I structure this correctly?

//Write all records in the DB
foreach (DataRow dr in dt.Rows)
{
    for (int i = 0; i < iColCount; i++)
    {
        if (!Convert.IsDBNull(dr[i]))
        {
            sw.Write(dr[i].ToString());
        }
        if (i < iColCount - 1)
        {
            sw.Write(",");
        }
    }
    sw.Write(sw.NewLine);
}

sw.Close();


"Live for today and let Tomorrow take care of itself"
AnswerRe: Help with export Pin
Prateek G20-Nov-07 21:30
Prateek G20-Nov-07 21:30 
GeneralRe: Help with export Pin
MumbleB20-Nov-07 22:55
MumbleB20-Nov-07 22:55 
Questionhow to retrieve value from port Pin
sivaramireddy p20-Nov-07 19:39
sivaramireddy p20-Nov-07 19:39 
QuestionConvert doc. to rtf Pin
arslanjatt20-Nov-07 19:27
arslanjatt20-Nov-07 19:27 
QuestionClearing TextBox Text Pin
sindhutiwari20-Nov-07 18:50
sindhutiwari20-Nov-07 18:50 
AnswerRe: Clearing TextBox Text Pin
Sun Rays20-Nov-07 19:21
Sun Rays20-Nov-07 19:21 
GeneralRe: Clearing TextBox Text Pin
sindhutiwari20-Nov-07 19:24
sindhutiwari20-Nov-07 19:24 
QuestionGraphing Control Pin
gongchengshi20-Nov-07 18:37
gongchengshi20-Nov-07 18:37 
AnswerRe: Graphing Control Pin
Paul Conrad20-Nov-07 18:46
professionalPaul Conrad20-Nov-07 18:46 
AnswerRe: Graphing Control Pin
gongchengshi20-Nov-07 19:15
gongchengshi20-Nov-07 19:15 
QuestionAbout dropdownlist.... Pin
Rajeshwar Code- Developer20-Nov-07 18:04
Rajeshwar Code- Developer20-Nov-07 18:04 
AnswerRe: About dropdownlist.... Pin
Christian Graus20-Nov-07 18:11
protectorChristian Graus20-Nov-07 18:11 
GeneralRe: About dropdownlist.... Pin
Rajeshwar Code- Developer20-Nov-07 18:37
Rajeshwar Code- Developer20-Nov-07 18:37 
GeneralRe: About dropdownlist.... Pin
Christian Graus20-Nov-07 18:46
protectorChristian Graus20-Nov-07 18:46 
AnswerRe: About dropdownlist.... Pin
arslanjatt20-Nov-07 19:50
arslanjatt20-Nov-07 19:50 
QuestionHow to click a button in a program Pin
sduhd20-Nov-07 17:11
sduhd20-Nov-07 17:11 
AnswerRe: How to click a button in a program Pin
MohammadAmiry20-Nov-07 17:47
MohammadAmiry20-Nov-07 17:47 

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.