Click here to Skip to main content
15,920,508 members
Home / Discussions / C#
   

C#

 
Question[Solved]Setting Bold Fonts on Nodes of a TreeView Pin
Sebastian Schneider18-Oct-06 1:51
Sebastian Schneider18-Oct-06 1:51 
AnswerRe: Setting Bold Fonts on Nodes of a TreeView Pin
Robert Rohde18-Oct-06 2:04
Robert Rohde18-Oct-06 2:04 
GeneralRe: Setting Bold Fonts on Nodes of a TreeView Pin
Sebastian Schneider18-Oct-06 2:06
Sebastian Schneider18-Oct-06 2:06 
Questionmerging files Pin
Yustme18-Oct-06 1:49
Yustme18-Oct-06 1:49 
AnswerRe: merging files Pin
Christian Graus18-Oct-06 2:03
protectorChristian Graus18-Oct-06 2:03 
GeneralRe: merging files Pin
Yustme18-Oct-06 2:16
Yustme18-Oct-06 2:16 
GeneralRe: merging files Pin
Christian Graus18-Oct-06 4:07
protectorChristian Graus18-Oct-06 4:07 
AnswerRe: merging files Pin
Larantz19-Oct-06 12:10
Larantz19-Oct-06 12:10 
You could do the reading and merging along the lines of this:

private int nr_of_checkboxes = 10;
private List<CheckBox> checkboxes = new List<CheckBox>(nr_of_checkboxes);
private Dictionary<CheckBox, string> checkboxDictionary = new Dictionary<CheckBox, string>(nr_of_checkboxes);


private void InitializeControls()
{
   for(int i = 0; i < nr_of_checkboxes; i++)
   {
      checkboxes.Add(new CheckBox());
      checkboxDictionary.Add(checkboxes[i], File.ReadAllText("file" + i + ".txt"));
   }
}


public void MergeAndWriteFiles()
{
   string merged_strings= "";

   foreach(CheckBock chkbox in checkboxes)
   {
      if(chkbox.Checked)
         merged_strings += checkboxDictionary.TryGetValue(chkbox);
   }

   File.WriteAllText("CombinedFiles.txt", merged_strings);
}


Took it all outta my head here, so there might be spellingerrors or other syntaxerrors, but it should point you to a working solution. Smile | :)

Hope it will be of some help.

-Larantz-



for those about to code, we salute you

Questionhow to insert picture in MS ACCESS table Pin
PavanPareta18-Oct-06 1:32
PavanPareta18-Oct-06 1:32 
AnswerRe: how to insert picture in MS ACCESS table Pin
Christian Graus18-Oct-06 1:33
protectorChristian Graus18-Oct-06 1:33 
Questiontrapping sqlexception Pin
DownBySpj18-Oct-06 1:23
DownBySpj18-Oct-06 1:23 
AnswerRe: trapping sqlexception Pin
Paul Brower18-Oct-06 4:56
Paul Brower18-Oct-06 4:56 
QuestionHow to convert bmp or jpg into DICOM? Pin
Dejan Paunovic18-Oct-06 1:06
Dejan Paunovic18-Oct-06 1:06 
AnswerRe: How to convert bmp or jpg into DICOM? Pin
Christian Graus18-Oct-06 1:30
protectorChristian Graus18-Oct-06 1:30 
QuestionDatagrid and repeater allow paging Pin
iyoko18-Oct-06 0:45
iyoko18-Oct-06 0:45 
AnswerRe: Datagrid and repeater allow paging Pin
bhanu1234518-Oct-06 21:05
bhanu1234518-Oct-06 21:05 
GeneralRe: Datagrid and repeater allow paging Pin
iyoko21-Oct-06 5:34
iyoko21-Oct-06 5:34 
QuestionFtpClientConnection Pin
toink toink18-Oct-06 0:43
toink toink18-Oct-06 0:43 
QuestionChanging settings of an installed windows service. Pin
kulile18-Oct-06 0:33
kulile18-Oct-06 0:33 
QuestionInserting into a multiple Datasets with 1 method Pin
Gareth H17-Oct-06 23:49
Gareth H17-Oct-06 23:49 
AnswerRe: Inserting into a multiple Datasets with 1 method Pin
Robert Rohde18-Oct-06 0:10
Robert Rohde18-Oct-06 0:10 
GeneralRe: Inserting into a multiple Datasets with 1 method [modified] Pin
Gareth H18-Oct-06 1:51
Gareth H18-Oct-06 1:51 
GeneralRe: Inserting into a multiple Datasets with 1 method Pin
Robert Rohde18-Oct-06 3:28
Robert Rohde18-Oct-06 3:28 
GeneralRe: Inserting into a multiple Datasets with 1 method Pin
Gareth H19-Oct-06 23:41
Gareth H19-Oct-06 23:41 
GeneralRe: Inserting into a multiple Datasets with 1 method Pin
Robert Rohde20-Oct-06 21:38
Robert Rohde20-Oct-06 21:38 

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.