Not
Bu sayfaya erişim yetkilendirme gerektiriyor. Oturum açmayı veya dizinleri değiştirmeyi deneyebilirsiniz.
Bu sayfaya erişim yetkilendirme gerektiriyor. Dizinleri değiştirmeyi deneyebilirsiniz.
Bu örnek, Not Defteri uygulamasını başlatmak için yöntemini kullanır Shell ve ardından My.Computer.Keyboard.SendKeys yöntemini kullanarak tuş vuruşları göndererek bir cümle yazdırır.
Örnek
Dim ProcID As Integer
' Start the Notepad application, and store the process id.
ProcID = Shell("NOTEPAD.EXE", AppWinStyle.NormalFocus)
' Activate the Notepad application.
AppActivate(ProcID)
' Send the keystrokes to the Notepad application.
My.Computer.Keyboard.SendKeys("I ", True)
My.Computer.Keyboard.SendKeys("♥", True)
My.Computer.Keyboard.SendKeys(" Visual Basic!", True)
' The sentence I ♥ Visual Basic! is printed on Notepad.
Sağlam programlama
ArgumentException İstenen işlem tanımlayıcısı olan bir uygulama bulunamazsa bir özel durum oluşur.
.NET Framework Güvenliği
Shell işlevine yapılan çağrı, tam güven gerektirir (SecurityException sınıf).