示例#1
0
 private void textBoxMtDNA_DragDrop(object sender, DragEventArgs e)
 {
     if (e.Data.GetDataPresent(DataFormats.FileDrop))
     {
         string[] filePaths  = (string[])(e.Data.GetData(DataFormats.FileDrop));
         string   fasta_file = filePaths[0];
         //
         try
         {
             tbFASTA.Text      = File.ReadAllText(fasta_file);
             textBoxMtDNA.Text = GGKUtilLib.getMtDNAMarkers(fasta_file);
         }
         catch (Exception)
         {
             MessageBox.Show("Unable to extract mtDNA mutations from " + fasta_file);
         }
     }
 }