How can I recreate this functionality of accepting multiple files at once in the viewer and process them one after the other (I would add pages to the current document.
thx in advance.
You have to catch the DragDrop event like any other user control. This is quite easy, here an example in vb.net:
Code: Select all
Private Sub GdViewer1_DragEnter(sender As Object, e As DragEventArgs) Handles GdViewer1.DragEnter If e.Data.GetDataPresent(DataFormats.FileDrop) Then e.Effect = DragDropEffects.All End If End Sub Private Sub GdViewer1_DragDrop(sender As Object, e As DragEventArgs) Handles GdViewer1.DragDrop If e.Data.GetDataPresent(DataFormats.FileDrop) Then Dim files() As String = CType(e.Data.GetData(DataFormats.FileDrop), String()) 'do something with files() here End If End Sub
Who is online
Users browsing this forum: No registered users and 2 guests