title: How to display code modules(.cs) as items in a listbox?
body: <p>I'm currently working on a new GUI that has a <strong>listbox</strong> as a crucial element in it. So far I've managed to display and select <strong>multiple items</strong> in this listbox, which wasn't that big of a deal. </p>
  
  <p>My goal is to have several <strong>.cs files</strong>(maybe in further expansion als vb script files) in a <strong>folder within the project</strong>, which are properly displayed in the main view listbox and will be executed if the corresponding item in the listbox is selected.</p>
  
  <p>So far I've tried to build the listbox and all the other GUI stuff (buttons, text,...) and connected the listbox with a bindable collection of a script model(which is a own class for testing purposes at the moment and should be replaced with the correct .cs files) </p>
  
  <p>In the code below you can see the work around with this custom class and the selection check for multiple listbox items.</p>
  
  <pre><code>private void Run_Click(object sender, RoutedEventArgs e)
          {
              //Show user the scripts which are being processed, these are the previous selected Scripts
              List&lt;string&gt; selectedList = new List&lt;string&gt;();
              foreach (ScriptModel selectedScript in MainListBox.SelectedItems)
              {
                  selectedList.Add(selectedScript.Name.ToString());
              }
              //check if no Script was selected, and if so, just return/do nothing
              if (selectedList.Count() == 0) { return; }
              MessageBox.Show("The following Scripts will be processed: " + Environment.NewLine +
                      string.Join(Environment.NewLine, selectedList));
  
  
             //Call the Connection for Data-Export 
  
          }
  </code></pre>
  
  <pre><code>private BindableCollection&lt;ScriptModel&gt; _scriptscollection=new BindableCollection&lt;ScriptModel&gt;();
  
  public BindableCollection&lt;ScriptModel&gt; ScriptsCollection
          {
              get { return _scriptscollection; }
              set { _scriptscollection = value; }
          }
  
  </code></pre>
  
  <p><em>I would like to know, how I can replace(or connect) these custom class with actual .cs files (which are some kind of scripts) in a project folder, so that I can display these file names and select the corresponding files for execution. (so the connection should work both ways)</em></p>
  
  <p>I'm sorry if this question seems a bit weird and general, but I'm really confused about that.</p>