ddbcrip

ddbcrip

  • NA
  • 1
  • 0

parsing mhtml file via drag and drop

Dec 21 2004 4:50 PM
i'm trying to parse an mhtml file by simply dragging it onto a form (we have many that need parsing). anyway, i can't seem to get the handlers to recognize the data as anything but text, which adds hex codes to the document. Can anyone shed some light as to what I'm doing wrong? The code for the handlers is below. private void Form1_DragEnter(object sender, System.Windows.Forms.DragEventArgs e) { if (e.Data.GetDataPresent(DataFormats.FileDrop,false)) { e.Effect = DragDropEffects.Copy; } } private void Form1_DragDrop(object sender, System.Windows.Forms.DragEventArgs e) { foreach (string fn in (string[])e.Data.GetData(DataFormats.FileDrop,false) ) { ...... } }