C# 클립보드(Ctrl + C & V)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
using System;
using System.Windows;
 
class Program {
    [STAThread]
    static void Main()
    {
        if (Clipboard.ContainsImage())
            Console.WriteLine("이미지");
        if (Clipboard.ContainsText()) {
            Console.WriteLine("텍스트");
            Console.WriteLine(Clipboard.GetText());
        }
    }
}
 
cs


결과


참고자료

https://msdn.microsoft.com/ko-kr/library/system.windows.clipboard(v=vs.110).aspx

반응형