+92 332 4229 857 99ProjectIdeas@Gmail.com

Accessing Control Panel Items (Vb.net)




The following code shows you how to access control panel items.










Imports Shell32

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        ListBox1.Items.Add("appwiz.cpl") 'for opening install/uninstall program
        ListBox1.Items.Add("desk.cpl") 'for opening desktop properties
        ListBox1.Items.Add("hdwwiz.cpl") 'for opening device manager
        ListBox1.Items.Add("inetcpl.cpl") 'for opening internet properties
        ListBox1.Items.Add("intl.cpl") 'for opening region and language properties

End Sub

Private Sub btnOpen_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnOpen.Click

        Dim objShell As New Shell()
        objShell.ControlPanelItem(ListBox1.SelectedItem.ToString())

End Sub

0 comments: