F
fred
I am trying to put a FileDrop format and a Text format dataobject onto the
clipboard so that they are both available.
I seem to be able to do one or the other but when I try to put both on only
the last entry is available on the clipboard.
Dim FileDataObject As New DataObject
Dim TextDataObject As New DataObject
Dim FileNames() As String = {myFileName}
FileDataObject.SetData(DataFormats.FileDrop, FileNames)
Clipboard.SetDataObject(FileDataObject, True)
TextDataObject.SetData(DataFormats.Text, myFileName)
Clipboard.SetDataObject(TextDataObject, True)
If I run the above statements only the Text format data is available on the
clipboard. If I comment out the last line then the File Format data is
available.
Since they are different formats shouldn't they both be available at the
same time.
What am I doing wrong. How do I get both formats onto the clipboard.
Thanks,
Fred
clipboard so that they are both available.
I seem to be able to do one or the other but when I try to put both on only
the last entry is available on the clipboard.
Dim FileDataObject As New DataObject
Dim TextDataObject As New DataObject
Dim FileNames() As String = {myFileName}
FileDataObject.SetData(DataFormats.FileDrop, FileNames)
Clipboard.SetDataObject(FileDataObject, True)
TextDataObject.SetData(DataFormats.Text, myFileName)
Clipboard.SetDataObject(TextDataObject, True)
If I run the above statements only the Text format data is available on the
clipboard. If I comment out the last line then the File Format data is
available.
Since they are different formats shouldn't they both be available at the
same time.
What am I doing wrong. How do I get both formats onto the clipboard.
Thanks,
Fred