public SDTM_New_Domain_Form(SDTM_Overview parent)
        {
            Parent = parent;
            InitializeComponent();
            //Populate listbox with unused domains
            using (StreamReader file = File.OpenText("SDTM_Datasets_Template.statds"))
            {
                JsonSerializer serializer = new JsonSerializer();
                dt = (DataTable)serializer.Deserialize(file, typeof(DataTable));
            }
            foreach (SDTM_Domain domain in Instance.study.workingSDTM.All_Domains)
            {
                domainsInStudy.Add(domain.Domain_Name);
            }
            List<string> allSDTMdomains = dt.AsEnumerable().Select(x => x["Dataset"].ToString()).ToList();

            IEnumerable<string> notAlreadyInStudy = allSDTMdomains.Except(domainsInStudy).Distinct();
            foreach (string s in notAlreadyInStudy)
            {
                listBox1.Items.Add(s);
            }
            listBox1.Items.Add("Custom Domain");
            //end populate listboxs
            listBox1.SetSelected(0, true);
        }
Beispiel #2
0
 private void sDTMToolStripMenuItem1_Click(object sender, EventArgs e)
 {
     SDTM_Overview formSDTMBuilder = new SDTM_Overview();
     formSDTMBuilder.Show(dockPanel);
     formSDTMBuilder.setDockPanel(dockPanel);
 }