VB.Net by API/System.Windows.Forms/Clipboard

Материал из VB Эксперт
Перейти к: навигация, поиск

Clipboard.ContainsFileDropList()

  
Imports System.Drawing.Drawing2D
Imports System
Imports System.Drawing.Text
Imports System.Drawing
Imports System.Windows.Forms
Imports System.Math
Imports System.Xml.Serialization
Imports System.IO
Imports System.Collections.Specialized
Public Class MainClass
   Shared Sub Main()
        "Copy some files then run this program
        If Clipboard.ContainsFileDropList() Then
            Dim file_names As StringCollection = Clipboard.GetFileDropList()
            For Each file_name As String In file_names
                Console.WriteLine(file_name)
            Next file_name
        End If
   End Sub 
End Class


Clipboard.GetFileDropList()

  
Imports System.Drawing.Drawing2D
Imports System
Imports System.Drawing.Text
Imports System.Drawing
Imports System.Windows.Forms
Imports System.Math
Imports System.Xml.Serialization
Imports System.IO
Imports System.Collections.Specialized
Public Class MainClass
   Shared Sub Main()
        "Copy some files then run this program
        If Clipboard.ContainsFileDropList() Then
            Dim file_names As StringCollection = Clipboard.GetFileDropList()
            For Each file_name As String In file_names
                Console.WriteLine(file_name)
            Next file_name
        End If
   End Sub 
End Class