12-10-17, 02:11 PM
PHP كود :
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Load
SetClipboardViewer(Me.Handle)
End Sub
<Runtime.InteropServices.DllImport("User32.dll")> _
Public Shared Function SetClipboardViewer(ByVal hWndNewViewer As IntPtr) As IntPtr
End Function
Protected Overrides Sub WndProc(ByRef m As Message)
If m.Msg = &H308 Then
Me.TextBox1.Clear()
If Clipboard.GetText.Trim.StartsWith("https://www.youtube.com/watch?v=") Then
Me.TextBox1.Text = Clipboard.GetText
Me.WindowState = FormWindowState.Normal
Me.Activate()
End If
End If
MyBase.WndProc(m)
End Sub
