elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: Rompecabezas de Bitcoin, Medio millón USD en premios


+  Foro de elhacker.net
|-+  Programación
| |-+  Programación General
| | |-+  .NET (C#, VB.NET, ASP) (Moderador: kub0x)
| | | |-+  Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa
0 Usuarios y 1 Visitante están viendo este tema.
Páginas: [1] Ir Abajo Respuesta Imprimir
Autor Tema: Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa  (Leído 5,169 veces)
Lekim

Desconectado Desconectado

Mensajes: 268



Ver Perfil
Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa
« en: 5 Mayo 2016, 15:51 pm »

Hola

Este tutorial muestra como abrir tareas, ventanas y cuadros de diálogo especiales de Windows Vista / 7 o sistema posterior desde nuestro programa.

Supón que quieres abrir el dialogo "Agregar quitar programas". Bastaría simplemente con poner esto:

Código
  1. Process.Start("RunDll32.exe", "shell32.dll,Control_RunDLL appwiz.cpl,,0")

Sin embargo hay zonas que no es posible acceder usando Rundll32.exe.

Por ejemplo, el cuadro de diálogo: "Establecer asociaciones: Asociar un tipo de archivo o protocolo con un determinado programa"

Anteriormente en XP, este cuadro estaba disponible en 'Opciones de Carpeta', pero luego fue eliminado. Ahora hay que ir a Panel de Control/Programas predeterminados/Establecer programas predeterminados" (también es accesible desde el menú Inicio).

¿Cómo podemos hacer que nuestro programa abra diréctamente este cuadro de diálogo o ventana?
 
Pues utilizando este comando: "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc"

      
Código
  1. Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc")


Con la función Shell de VB sería así:
  
Código
  1. Shell("explorer.exe shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc", 1)


En Vista y posterior muchos ventanas y diálogos tienen su código CLSID. Por ejemplo para el Panel de Control el código es: {26EE0668-A00A-44D7-9371-BEB064C98683}
 
      
Código
  1. Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}")

Donde 'Shell:::{Code CLSID}\Número\", indica la sección del Panel de control:


Código
  1.        'Opcciones Adicionales"
  2.        Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\0\")
  3.  
  4.        'Apariencia y personalización"
  5.        Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\1\")
  6.  
  7.        'Hardware y sonido"
  8.        Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\")
  9.  
  10.        '"Redes e Internet"
  11.        Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\")
  12.  
  13.        '...
  14.  
  15.        '"Programas"
  16.        Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\")
  17.  


El código CLSID de "Programas predeterminados" es: {17cd9488-1228-4b2f-88ce-4298e93e0966}


El comando se crea añadiendo un CLSID al anterior, en este caso a 'Panel de control/Programas':
Código
  1. Process.Start("explorer.exe", "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}")


...y después la página:
Código
  1. "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc"


Pero no te preocupes más abajo muestro como conseguir los comandos completos y no tienes que inventar nada.


Para abrir el cuadro de diálogo "Propiedades de la barra de tareas y menú inicio" basta con usar este código:
Código
  1.  Process.Start("explorer.exe", "shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}")

Para el resto se usa rundll32.exe:

Código
  1.        'Opciones de carpeta/General
  2.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 0")
  3.  
  4.        'Barra de tareas
  5.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 1")
  6.  
  7.        'Opciones de carpeta/Buscar
  8.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 2")
  9.  
  10.        'Menú inicio
  11.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 3")
  12.  
  13.        'Área de notificación
  14.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 4")
  15.  
  16.        'Personalizar iconos de notificación
  17.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 5")
  18.  
  19.        'Barra de herramientas
  20.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 6")
  21.  
  22.        'Opciones de carpeta/Ver
  23.        Process.Start("rundll32.exe", "shell32.dll,Options_RunDLL 7")
  24.  
  25.  


DONDE ENCONTRAR ESTOS CAMINOS O COMANDOS PARA ACCEDER A ESTAS DETERMINADAS ZONAS DE WINDOWS
Bien que seguramente puedes encontrar muchos en Internet ya que no es ningún secreto, lo que quizás poca gente sabe es que los comandos y accesos a determinazas zonas de windows se encuentran en el recurso [XML] del archivo Shell32.dll.

Personalmente yo he utilizado  el programa Resource Hacker, desde el cual abres el archivo Shell32.dll que se haya en la carpeta C:\Windows\System32. Pero también puedes abrir Shell32.dll desde  VB.NET mediante "Agregar/Elemento Existente" (CTRL+D), entonces se te carga como un archivo de recursos en C++ y como archivo agregado en un proyecto Windows Forms. Desde el cual podrás acceder a su contenido.



Desde Resoruce Hacker el contenido XML es perfectamente legible, pero desde .NET, no tanto, ya que se muestra como binario. Si lo cargas desde NET, puedes hacer un copia y pega en el Notepad ya que el texto del recurso XML en realidad es un simple texto plano.


La información XML del archivo Shell32.dll, da cuatro datos respecto a una tarea de windows. Primero la información de la tarea '<!-- Change screen reader -->', luego el ID, Nombre, Keywords y comando:
Código
  1. ...
  2. <!-- Change screen reader -->
  3.        <sh:task id="{B57D7134-6BAB-47B2-A506-E885E104EC99}">
  4.              <sh:name>@shell32.dll,-24754</sh:name>
  5.              <sh:keywords>@shell32.dll,-24755</sh:keywords>
  6.              <sh:command>shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageNoVisual</sh:command>
  7.        </sh:task>
  8. ...
  9.  

ABRIR TODAS LAS TAREAS DE WINDOWS

Mal llamado GodMode (modo dios) o MasterPanel, ya que su verdadero nombre es "All Task" en inglés o "Todas las tareas"
Código
  1.        Process.Start("explorer.exe", "shell:::{ed7ba470-8e54-465e-825c-99712043e01c}")

ABRIR ALGUNAS CARPETAS ESPECIALES
Código
  1.  
  2.      'Herramientas administrativas               shell:::{D20EA4E1-3957-11d2-A40B-0C5020524153}
  3.        'Panel de Control                           shell:::{21EC2020-3AEA-1069-A2DD-08002b30309d}
  4.        'Fuentes                                    shell:::{D20EA4E1-3957-11d2-A40B-0C5020524152}
  5.        'Equipo                                     shell:::{20D04FE0-3AEA-1069-A2D8-08002B30309D}
  6.        'Documentos                                 shell:::{450D8FBA-AD25-11D0-98A8-0800361B1103}
  7.        'History                                    shell:::{ff393560-c2a7-11cf-bff4-444553540000}
  8.        'Red (WORKGROUP)                            shell:::{208d2c60-3aea-1069-a2d7-08002b30309d}
  9.        'Impresoras                                 shell:::{2227A280-3AEA-1069-A2DE-08002B30309D}
  10.        'Programs Folder                            shell:::{7be9d83c-a729-4d97-b5a7-1b7313c39e0a}
  11.        'Papelera de reciclaje                      shell:::{645FF040-5081-101B-9F08-00AA002F954E}
  12.        'Menú Inicio                                shell:::{48e7caab-b918-4e58-a94d-505519c795dc}
  13.        'Información y herramientas de rendimiento  shell:::{78F3955E-3B90-4184-BD14-5397C15F1EFC}
  14.        'Centro de accesibilidad                    shell:::{D555645E-D4F8-4c29-A827-D93C859C4F2A}
  15.        'Windows Defender                           shell:::{D8559EB9-20C0-410E-BEDA-7ED416AECC2A}
  16.        'Mapa de red                                shell:::{E7DE9B1A-7533-4556-9484-B26FB486475E}
  17.        'Windows SideShow                           shell:::{E95A4861-D57A-4be1-AD0F-35267E261739}
  18.        'Personalización                            shell:::{ED834ED6-4B5A-4bfe-8F11-A626DCB6A921}
  19.        'Informe de problemas y soluciones          shell:::{FCFEECAE-EE1B-4849-AE50-685DCF7717EC}
  20.        'Escáneres y cámaras                        shell:::{00f2886f-cd64-4fc9-8ec5-30ef6cdbe8c3}
  21.        'Opciones de energía                        shell:::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}
  22.        'Propiedades barra de tareas                shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}
  23.        'Obtener programas                          shell:::{15eae92e-f17a-4431-9f28-805e482dafd4}
  24.        'Programas predeterminados                  shell:::{17cd9488-1228-4b2f-88ce-4298e93e0966}
  25.        'Dispositivos Bluetooth                     shell:::{28803F59-3A75-4058-995F-4EE5503B023C}
  26.        'Centro de copias de seguridad y restauración   shell:::{335a31dd-f04b-4d76-a925-d6b47cf360df}
  27.        'Windows Update                             shell:::{36eef7db-88ad-4e81-ad49-0e313f0c35f8}
  28.        'Propiedades de Windows Sidebar             shell:::{37efd44d-ef8d-41b1-940d-96973a50e9e0}
  29.        'Get Programs Online                        shell:::{3e7efb4c-faf1-453d-89eb-56026875ef90}
  30.        'Firewall de Windows                        shell:::{4026492F-2F69-46B8-B9BF-5654FC07E423}
  31.        'Opciones de reconocimiento de voz          shell:::{58E3C745-D971-4081-9034-86E34B30836A}
  32.        'Desfragmentador de disco                   shell:::{5d9a6bda-b06a-42c0-b50f-5174bcb472de}
  33.        'Centro de movilidad de Windows             shell:::{5ea4f148-308c-46d7-98a9-49041b1dd468}
  34.        'Cuentas de usuario                         shell:::{60632754-c523-4b62-b45c-4172da012619}
  35.        'Opciones de carpeta                        shell:::{6DFD7C5C-2451-11d3-A299-00C04F8EF6AF}
  36.        'Administrador de dispositivos              shell:::{74246bfc-4c96-11d0-abef-0020af6b0b7a}
  37.        'Windows CardSpace                          shell:::{78CB147A-98EA-4AA6-B0DF-C8681F69341C}
  38.  
  39.        Process.Start("explorer.exe", "shell:::{78F3955E-3B90-4184-BD14-5397C15F1EFC}")
  40.  



ALGUNAS TAREAS
Código:


Accommodate learning abilities:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageQuestionsCognitive

Accommodate low vision:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToSee

Adjust screen resolution for reading:
%windir%\system32\control.exe desk.cpl,Settings,@Settings

Change how your keyboard works:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageKeyboardEasierToUse

Change how your mouse works:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToClick

Change screen reader:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageNoVisual

Change the Narrator voice:
%windir%\system32\narrator.exe

Control the computer without the mouse or keyboard:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageNoMouseOrKeyboard

Hear a tone when keys are pressed:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageFilterKeysSettings

Hear text read aloud with Narrator:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}

Ignore repeated keystrokes using FilterKeys:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageFilterKeysSettings

Let Windows suggest Ease of Access settings:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageQuestionsEyesight

Magnify portions of the screen using Magnifier:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToSee

Move the pointer with the keypad using MouseKeys:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageKeyboardEasierToUse

Optimize for blindness:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageNoVisual

Optimize visual display:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToSee

Press key combinations one at a time:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageKeyboardEasierToUse

Replace sounds with visual cues:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierWithSounds

Turn High Contrast on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}

Turn Magnifier on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}

Turn off background images:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToSee

Turn off unnecessary animations:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToSee

Turn On-Screen keyboard on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}

Underline keyboard shortcuts and access keys:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageKeyboardEasierToUse

Use audio description for video:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}\pageEasierToSee

View current accessibility settings:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\7\::{D555645E-D4F8-4c29-A827-D93C859C4F2A}

Create and format hard disk partitions:
%windir%\system32\mmc.exe %windir%\system32\diskmgmt.msc

Defragment your hard drive:
%windir%\system32\dfrgui.exe

Diagnose your computer's memory problems:
%windir%\system32\mdsched.exe

Edit group policy:
%windir%\system32\mmc.exe %windir%\system32\gpedit.msc

Generate a system health report:
%windir%\system32\perfmon.exe /report

How to add new hardware:
mshelp://windows/?id=dfd48704-eb89-4e9f-b3de-552f0ca60640

Schedule tasks:
%windir%\system32\mmc.exe %windir%\system32\taskschd.msc

Set up data sources (ODBC):
%windir%\system32\odbcad32.exe

Set up iSCSI initiator:
%windir%\system32\iscsicpl.exe

View event logs:
%windir%\system32\mmc.exe %windir%\system32\eventvwr.msc

View event logs:
%windir%\system32\mmc.exe %windir%\system32\eventvwr.msc

View local services:
%windir%\system32\mmc.exe %windir%\system32\services.msc

Add or remove programs:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{7B81BE6A-CE2B-4676-A29E-EB907A5126C5}

Change or remove a program:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{7B81BE6A-CE2B-4676-A29E-EB907A5126C5}

How to install a program:
mshelp://windows/?id=fe7ea80e-52a2-48d6-947a-05e02e78bc37

Install a program from the network:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{15EAE92E-F17A-4431-9F28-805E482dAFD4}

Show which programs are installed on my computer:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{7B81BE6A-CE2B-4676-A29E-EB907A5126C5}

Turn Windows features on or off:
%windir%\system32\OptionalFeatures.exe

Turn Windows features on or off:
%windir%\system32\CompMgmtLauncher.exe

Uninstall a program:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{7B81BE6A-CE2B-4676-A29E-EB907A5126C5}

View installed updates:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{7B81BE6A-CE2B-4676-A29E-EB907A5126C5}\::{D450A8A1-9568-45C7-9C0E-B4F9FB4537BD}

Change default e-mail program:
%windir%\system32\ComputerDefaults.exe

Change default programs that Windows uses:
%windir%\system32\ComputerDefaults.exe

Make a file type always open in a specific program:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc

Set program defaults for this computer:
%windir%\system32\ComputerDefaults.exe

Set your default programs:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageDefaultProgram

Use an older program with this version of Windows:
%windir%\system32\mshta.exe res://%windir%\system32\acprgwiz.dll/compatmode.hta

Change settings for a Bluetooth enabled device:
%windir%\system32\control.exe bthprops.cpl,,1

Set up a Bluetooth enabled device:
%windir%\system32\control.exe bthprops.cpl

Back up your computer:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{335a31dd-f04b-4d76-a925-d6b47cf360df}

Restore data, files, or computer from backup:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{335a31dd-f04b-4d76-a925-d6b47cf360df}

Schedule automated backups:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{335a31dd-f04b-4d76-a925-d6b47cf360df}

Change advanced color management settings for displays, scanners, and printers:
%windir%\system32\colorcpl.exe

Add clocks for different time zones:
%windir%\system32\control.exe timedate.cpl,,1

Automatically adjust for daylight saving time:
%windir%\system32\control.exe timedate.cpl

Change the time zone:
%windir%\system32\control.exe timedate.cpl

Set the time and date:
%windir%\system32\control.exe timedate.cpl

Find which version of Windows you are using:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{CB1B7F8C-C50A-4176-B604-9E24DEE8D4D1}

Get started with Windows:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{CB1B7F8C-C50A-4176-B604-9E24DEE8D4D1}

Migrate files and settings from one computer to another:
%windir%\system32\migwiz\migwiz.exe

Check for new solutions:
%windir%\system32\wercon.exe -solutioncheck

Choose how to check for solutions:
%windir%\system32\wercon.exe -showweropts

View problem history:
%windir%\system32\wercon.exe -problemhistory

Change default settings for media or devices:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{9C60DE1E-E5FC-40f4-A487-460851A8D915}

Play CDs or other media automatically:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{9C60DE1E-E5FC-40f4-A487-460851A8D915}

Start or stop using autoplay for all media and devices:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{9C60DE1E-E5FC-40f4-A487-460851A8D915}

Change search options for files and folders:
%windir%\system32\rundll32.exe shell32.dll,Options_RunDLL 2

Change the file type associated with a file extension:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc

Show hidden files and folders:
%windir%\system32\rundll32.exe shell32.dll,Options_RunDLL 7

Show or hide file extensions:
%windir%\system32\rundll32.exe shell32.dll,Options_RunDLL 7

Specify single- or double-click to open:
shell:::{6DFD7C5C-2451-11D3-A299-00C04F8EF6AF}

Use Classic Windows folders:
shell:::{6DFD7C5C-2451-11D3-A299-00C04F8EF6AF}

Install or remove a font:
%windir%\system32\control.exe /name Microsoft.Fonts

View installed fonts:
%windir%\system32\control.exe /name Microsoft.Fonts

Set up USB game controllers:
%windir%\system32\control.exe joy.cpl

Adjust commonly used mobility settings:
%windir%\system32\mblctr.exe /open

Adjust screen brightness:
%windir%\system32\mblctr.exe /open

Adjust settings before giving a presentation:
%windir%\system32\presentationsettings.exe

Connect to a projector or other external display:
%windir%\system32\mblctr.exe /open

Block or allow pop-ups:
%windir%\system32\control.exe inetcpl.cpl,,2

Block or allow third-party cookies:
%windir%\system32\control.exe inetcpl.cpl,,2

Change how web pages are displayed in tabs:
%windir%\system32\control.exe inetcpl.cpl,,0

Change security settings:
%windir%\system32\control.exe inetcpl.cpl,,1

Change temporary Internet file settings:
%windir%\system32\control.exe inetcpl.cpl,,0

Change the default Web browser:
%windir%\system32\ComputerDefaults.exe

Change the search provider in Internet Explorer:
%windir%\system32\control.exe inetcpl.cpl,,0

Change your homepage:
%windir%\system32\control.exe inetcpl.cpl,,0

Configure proxy server:
%windir%\system32\control.exe inetcpl.cpl,,4

Connect to the Internet:
%windir%\system32\rundll32.exe xwizards,RunWizard {7071ECA0-663B-4bc1-A1FA-B97F3B917C55} /z -ShowFinishPage

Delete browsing history:
%windir%\system32\control.exe inetcpl.cpl,,0

Delete cookies or temporary files:
%windir%\system32\control.exe inetcpl.cpl,,0

Enable or disable session cookies:
%windir%\system32\control.exe inetcpl.cpl,,2

Manage browser add-ons:
%windir%\system32\control.exe inetcpl.cpl,,5

Tell if an RSS feed is available on a website:
%windir%\system32\control.exe inetcpl.cpl,,3

Turn autocomplete in Internet Explorer on or off:
%windir%\system32\control.exe inetcpl.cpl,,3

Change cursor blink rate:
%windir%\system32\control.exe /name Microsoft.Keyboard

Check keyboard status:
%windir%\system32\control.exe /name Microsoft.Keyboard /page 1

Change button settings:
%windir%\system32\control.exe main.cpl

Change how the mouse pointer looks:
%windir%\system32\control.exe main.cpl,,1

Change how the mouse pointer looks when it's moving:
%windir%\system32\control.exe main.cpl,,2

Change mouse click settings:
%windir%\system32\control.exe main.cpl

Change mouse wheel settings:
%windir%\system32\control.exe main.cpl,,3

Change the mouse pointer display or speed:
%windir%\system32\control.exe main.cpl,,2

Customize the mouse buttons:
%windir%\system32\control.exe main.cpl

Make it easier to see the mouse pointer:
%windir%\system32\control.exe main.cpl,,2

Add gadgets to Sidebar:
%programfiles%\windows sidebar\sidebar.exe /showgadgets

Add the Clock gadget to Windows Sidebar:
%programfiles%\windows sidebar\sidebar.exe /showgadgets

Choose whether to keep Sidebar on top of other windows:
%programfiles%\windows sidebar\sidebar.exe /cpl

Uninstall a gadget:
%programfiles%\windows sidebar\sidebar.exe /uninstallgadgets

Compare features with your current configuration:
%windir%\system32\WindowsAnytimeUpgrade.exe /UpgradeOnline

Get new programs online at Windows Marketplace:
%windir%\system32\rundll32.exe %windir%\system32\appwiz.cpl,GetProgramsOnline

Manage programs you buy online (digital locker):
%windir%\DigitalLocker\digitalx.exe

Enable offline files:
%windir%\system32\control.exe cscui.dll,,0

Encrypt your offline files:
%windir%\system32\control.exe cscui.dll,,2

Manage disk space used by your offline files:
%windir%\system32\control.exe cscui.dll,,1

Set up parental controls for any user:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{96AE8D84-A250-4520-95A5-A47A7E3C548B}

View activity reports:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{96AE8D84-A250-4520-95A5-A47A7E3C548B}\pageActivityViewer

View parental control settings for your account:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{96AE8D84-A250-4520-95A5-A47A7E3C548B}\pageUserHub

Set up dialing rules:
%windir%\system32\control.exe telephon.cpl

Install drivers for older devices with Add Hardware wizard:
%windir%\system32\hdwwiz.exe

Update device drivers:
%windir%\system32\mmc.exe devmgmt.msc

View hardware and devices:
%windir%\system32\mmc.exe devmgmt.msc

View hardware and devices:
%windir%\system32\mmc.exe devmgmt.msc

Change battery settings:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}

Change power-saving settings:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}

Change what closing the lid does:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}\pageGlobalSettings

Change what the power buttons do:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}\pageGlobalSettings

Change when the computer sleeps:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}\pagePlanSettings

Choose when to turn off display:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}\pagePlanSettings

Require a password when the computer wakes:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}\pageGlobalSettings

Turn hibernation on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{025A5937-A6BE-4686-A844-36FE4BEC8B6D}\pagePlanSettings

Add a printer:
%windir%\system32\rundll32.exe printui.dll,PrintUIEntry /il

Change default printer:
%windir%\system32\control.exe /name Microsoft.Printers

Remove a printer:
%windir%\system32\control.exe /name Microsoft.Printers

Send a fax:
%windir%\system32\wfs.exe

Send a fax:
%windir%\system32\wfs.exe

View all printers:
%windir%\system32\control.exe /name Microsoft.Printers

Change display language:
%windir%\system32\control.exe intl.cpl,,/p:&quot;keyboard&quot;

Change keyboards or other input methods:
%windir%\system32\control.exe intl.cpl,,/p:&quot;keyboard&quot;

Change the country or region:
%windir%\system32\control.exe intl.cpl,,/p:&quot;location&quot;

Change the date, time, or number format:
%windir%\system32\control.exe intl.cpl

Change the languages used for partially translated menus and dialogs:
%windir%\system32\control.exe intl.cpl,,/p:&quot;keyboard&quot;

Change the way currency is displayed:
%windir%\system32\control.exe intl.cpl

Change the way dates and lists are displayed:
%windir%\system32\control.exe intl.cpl

Change the way measurements are displayed:
%windir%\system32\control.exe intl.cpl

Change the way time is displayed:
%windir%\system32\control.exe intl.cpl

Install or uninstall display languages:
%windir%\system32\lpksetup.exe

Scan a document or picture:
%windir%\system32\wfs.exe

Scan a document or picture:
%windir%\system32\wfs.exe

View scanners and cameras:
%ProgramFiles%\Windows Photo Gallery\ImagingDevices.exe

Change how Windows searches:
%windir%\system32\control.exe srchadmin.dll,,2

Check firewall status:
%windir%\system32\FirewallSettings.exe

Check this computer's security status:
%windir%\system32\control.exe wscui.cpl

Adjust system volume:
%windir%\system32\sndvol.exe

Change sound card settings:
%windir%\system32\control.exe mmsys.cpl,,0

Change system sounds:
%windir%\system32\control.exe mmsys.cpl,,2

Manage audio devices:
%windir%\system32\control.exe mmsys.cpl ,,0

Change text to speech settings:
%windir%\system32\control.exe %windir%\system32\speech\speechux\sapi.cpl

Print the speech reference card:
mshelp://windows/?id=f968a8dd-011d-40fe-84be-93273d6580f0

Set up a microphone:
%windir%\system32\rundll32.exe %windir%\system32\speech\speechux\SpeechUX.dll,RunWizard MicTraining

Start speech recognition:
%windir%\speech\common\sapisvr.exe -SpeechUX

Take speech tutorials:
%windir%\system32\rundll32.exe %windir%\system32\speech\speechux\SpeechUX.dll,RunWizard Tutorial

Train the computer to recognize your voice:
%windir%\system32\rundll32.exe %windir%\system32\speech\speechux\SpeechUX.dll,RunWizard UserTraining

Resolve sync conflicts:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{9C73F5E5-7AE7-4E32-A8E8-8D23B85255BF}\::{E413D040-6788-4C22-957E-175D1C513A34}

Sync with other computers, mobile devices, or network folders:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{9C73F5E5-7AE7-4E32-A8E8-8D23B85255BF}

View sync results:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{9C73F5E5-7AE7-4E32-A8E8-8D23B85255BF}\::{BC48B32F-5910-47F5-8570-5074A8A5636A}

Activate Windows:
%windir%\system32\slui.exe

Adjust the appearance and performance of Windows:
%windir%\system32\SystemPropertiesPerformance.exe

Allow remote access to your computer:
%windir%\system32\SystemPropertiesRemote.exe

Allow Remote Assistance invitations to be sent from this computer:
%windir%\system32\SystemPropertiesRemote.exe

Change workgroup name:
%windir%\system32\SystemPropertiesComputerName.exe

Check processor speed:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

Configure advanced user profile properties:
%windir%\system32\rundll32.exe sysdm.cpl,EditUserProfiles

Create a restore point:
%windir%\system32\SystemPropertiesProtection.exe

Edit environment variables for your account:
%windir%\system32\rundll32.exe sysdm.cpl,EditEnvironmentVariables

Edit the system environment variables:
%windir%\system32\SystemPropertiesAdvanced.exe

How to change the size of virtual memory:
mshelp://windows/?id=89ca317f-649d-40a6-8934-e5707ee5c4b8

Join a domain:
%windir%\system32\SystemPropertiesComputerName.exe

Rename this computer:
%windir%\system32\SystemPropertiesComputerName.exe

Restore system files and settings from a restore point:
%windir%\system32\rstrui.exe

See the name of this computer:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

Select users who can use remote desktop:
%windir%\system32\SystemPropertiesRemote.exe

Show how much RAM is on this computer:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

Show which domain my computer is on:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

Show which operating system my computer is running:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

Show which workgroup this computer is on:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

Turn automatic creation of restore points on or off:
%windir%\system32\SystemPropertiesProtection.exe

View advanced system settings:
%windir%\system32\SystemPropertiesAdvanced.exe

View basic information about your computer:
shell:::{26ee0668-a00a-44d7-9371-beb064c98683}\5\::{BB06C0E4-D293-4f75-8A90-CB05B6477EEE}

View running processes with Task Manager:
%windir%\system32\taskmgr.exe

Auto-hide the taskbar:
shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}

Change Start menu to Classic view:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 3

Customize icons on the taskbar:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 4

Customize the Start menu:
%windir%\system32\rundll32.exe shell32.dll,Options_RunDLL 3

Customize the taskbar:
shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}

Find missing Start menu:
shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}

Group similar windows on the taskbar:
shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}

Lock or unlock the taskbar:
shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}

Organize Start menu:
%windir%\system32\rundll32.exe shell32.dll,Options_RunDLL 3

Remove icons from notification area (system tray) on the desktop:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 4

Restore Start menu defaults:
%windir%\system32\rundll32.exe shell32.dll,Options_RunDLL 3

Show or hide inactive icons on the taskbar:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 4

Show or hide the notification area on the taskbar:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 4

Show or hide the Quick Launch toolbar on the taskbar:
shell:::{0DF44EAA-FF21-4412-828E-260A8728E7F1}

Show or hide volume (speaker) icon on the taskbar:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 4

Turn toolbars on the taskbar on or off:
%windir%\System32\rundll32.exe shell32.dll,Options_RunDLL 6

Add or remove user accounts:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageAdminTasks

Change account type:
%windir%\system32\netplwiz.exe

Change your account picture:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pagePickMyPicture

Change your Windows password:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}

Create a password reset disk:
%windir%\system32\rundll32.exe keymgr.dll,PRShowSaveWizardExW

Create administrator account:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageAdminTasks\pageNameNewAccount

Create an account:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageAdminTasks\pageNameNewAccount

Create or remove your account password:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}

Create standard user account:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageAdminTasks\pageNameNewAccount

Edit local users and groups:
%windir%\system32\mmc.exe %windir%\system32\lusrmgr.msc

Give administrative rights to a domain user:
%windir%\system32\netplwiz.exe

Give other users access to this computer:
%windir%\system32\netplwiz.exe

How to change your Windows password:
mshelp://windows/?id=5c07e067-286d-4b8d-b342-431306e696aa

Make changes to accounts:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageAdminTasks

Manage file encryption certificates:
%windir%\system32\rekeywiz.exe

Manage network passwords:
%windir%\system32\rundll32.exe keymgr.dll KRShowKeyMgr

Turn guest account on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageAdminTasks

Turn User Account Control (UAC) on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\9\::{60632754-c523-4b62-b45c-4172da012619}\pageChangeSecuritySettings

Allow a program through Windows Firewall:
%windir%\system32\FirewallSettings.exe 1

Turn Windows Firewall on or off:
%windir%\system32\FirewallSettings.exe

Get new programs online at Windows Marketplace:
%windir%\system32\rundll32.exe %windir%\system32\appwiz.cpl,GetProgramsOnline

Manage programs you buy online (digital locker):
%windir%\DigitalLocker\digitalx.exe

Check for updates:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\10\::{36eef7db-88ad-4e81-ad49-0e313f0c35f8}

Turn automatic updating on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\10\::{36eef7db-88ad-4e81-ad49-0e313f0c35f8}\pageSettings

Check your computer's Windows Experience Index base score:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{78F3955E-3B90-4184-BD14-5397C15F1EFC}

Free up disk space by deleting unnecessary files:
%windir%\system32\cleanmgr.exe

Use tools to improve performance:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\5\::{78F3955E-3B90-4184-BD14-5397C15F1EFC}

Manage BitLocker keys:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\10\::{D9EF8727-CAC2-4e60-809E-86F80A666C91}

Protect your computer by encrypting data on your disk:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\10\::{D9EF8727-CAC2-4e60-809E-86F80A666C91}

Change People Near Me settings:
%windir%\system32\control.exe collab.cpl,,2

Sign in or out of People Near Me:
%windir%\system32\control.exe collab.cpl,,1

Change pen flicks settings:
%windir%\system32\control.exe TabletPC.cpl @0,flicks

Change tablet pen settings:
%windir%\system32\control.exe TabletPC.cpl @0,pen

Enable or disable handwriting personalization:
%windir%\system32\control.exe TabletPC.cpl @1,handwriting

Turn pen flicks on and off:
%windir%\system32\control.exe TabletPC.cpl @0,flicks

Turn the touch pointer on and off:
%windir%\system32\control.exe TabletPC.cpl @0,touch

Calibrate the screen:
%windir%\system32\control.exe TabletPC.cpl @1,general

Change screen orientation:
%windir%\system32\control.exe TabletPC.cpl @1,display

Set tablet buttons to perform certain tasks:
%windir%\system32\control.exe TabletPC.cpl @1,buttons

Specify which hand I write with:
%windir%\system32\control.exe TabletPC.cpl @1,general

Send or receive a file:
%windir%\system32\control.exe irprops.cpl

Change device settings:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{E95A4861-D57A-4be1-AD0F-35267E261739}\pageChangeSettingsDeviceSelector

Change the order of gadgets:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{E95A4861-D57A-4be1-AD0F-35267E261739}\pageReorderGadgetsDeviceSelector

Configure an auxiliary display:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{E95A4861-D57A-4be1-AD0F-35267E261739}

Set up a secondary display to use with Windows SideShow:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{E95A4861-D57A-4be1-AD0F-35267E261739}

Turn gadgets on or off:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{E95A4861-D57A-4be1-AD0F-35267E261739}

Wake computer to update devices:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\2\::{E95A4861-D57A-4be1-AD0F-35267E261739}\pageAutoWake

Adjust font size (DPI):
%windir%\system32\DpiScaling.exe

Adjust screen resolution:
%windir%\system32\control.exe desk.cpl,Settings,@Settings

Change desktop background:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\1\::{ED834ED6-4B5A-4bfe-8F11-A626DCB6A921}\pageWallpaper

Change display settings:
%windir%\system32\control.exe desk.cpl,Settings,@Settings

Change screen saber:
%windir%\system32\control.exe desk.cpl,screensaver,@screensaver

Change size of on-screen items:
%windir%\system32\DpiScaling.exe

Change the color scheme:
%windir%\system32\control.exe desk.cpl,appearance,@appearance

Change the theme:
%windir%\system32\control.exe desk.cpl,Themes,@Themes

Customize colors:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\1\::{ED834ED6-4B5A-4bfe-8F11-A626DCB6A921}\pageColorization

Enable or disable transparent glass on windows:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\1\::{ED834ED6-4B5A-4bfe-8F11-A626DCB6A921}\pageColorization

How to correct monitor flicker (refresh rate):
mshelp://windows/?id=52f7448b-d524-44e4-b43d-15b5a2968537

How to use ClearType to sharpen the screen text:
mshelp://windows/?id=c3a4da66-c335-45f5-a71f-d162d1b64ed4

Lock the computer when I leave it alone for a period of time:
%windir%\system32\control.exe desk.cpl,screensaver,@screensaver

Set screen saber password:
%windir%\system32\control.exe desk.cpl,screensaver,@screensaver

Set up computer to use multiple monitors:
%windir%\system32\control.exe desk.cpl,Monitor,@Monitor

Show or hide common icons on the desktop:
%windir%\system32\control.exe desk.cpl,,0

Turn screen saber on or off:
%windir%\system32\control.exe desk.cpl,screensaver,@screensaver

View the name of the video card:
%windir%\system32\control.exe desk.cpl,Settings,@Settings

Manage Information Cards that are used to log on to online services:
%windir%\system32\control.exe /name Microsoft.CardSpace

Add a device to the network:
%windir%\system32\rundll32.exe %systemroot%\System32\xwizards.dll,RunWizard {d1a4299a-0adf-11da-b070-0011856571de}

Connect to a network:
shell:::{21EC2020-3AEA-1069-A2DD-08002B30309D}\::{38A98528-6CBF-4CA9-8DC0-B1E1D10F7B1B}

Connect to a wireless network:
%windir%\system32\rundll32.exe xwizards,RunWizard {7071ECE0-663B-4bc1-A1FA-B97F3B917C55} /z -ShowFinishPage

Identify and repair network problems:
%windir%\system32\Rundll32.exe ndfapi,NdfRunDllDiagnoseIncident

Manage saved networks:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{8E908FC9-BECC-40f6-915B-F4CA0E70D03D}

Manage wireless networks:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{1FA9085F-25A2-489B-85D4-86326EEDCD87}

Set up a dial-up connection:
%windir%\system32\rundll32.exe xwizards,RunWizard {7071ECE0-663B-4bc1-A1FA-B97F3B917C55} /z -ShowFinishPage

Set up a virtual private network (VPN) connection:
%windir%\system32\rundll32.exe xwizards,RunWizard {7071ECE0-663B-4bc1-A1FA-B97F3B917C55} /z -ShowFinishPage

Set up an ad hoc (computer-to-computer) network:
%windir%\system32\rundll32.exe xwizards,RunWizard {7071ECE0-663B-4bc1-A1FA-B97F3B917C55} /z -ShowFinishPage

Set up file sharing:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{8E908FC9-BECC-40f6-915B-F4CA0E70D03D}

Share printers:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{8E908FC9-BECC-40f6-915B-F4CA0E70D03D}

View network computers and devices:
shell:::{F02C1A0D-BE21-4350-88B0-7367FC96EF3C}

View network connections:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{7007ACC7-3202-11D1-AAD2-00805FC1270E}

View network status and tasks:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\3\::{8E908FC9-BECC-40f6-915B-F4CA0E70D03D}

Scan for spyware and other potentially unwanted software:
%ProgramFiles%\windows defender\MSASCui.exe -quickscan

Stop a program from running at startup:
%ProgramFiles%\windows defender\MSASCui.exe -showSWE:Startup

View currently running programs:
%ProgramFiles%\windows defender\MSASCui.exe -showSWE:Running



« Última modificación: 5 Mayo 2016, 21:22 pm por Lekim » En línea

Eleкtro
Ex-Staff
*
Desconectado Desconectado

Mensajes: 9.788



Ver Perfil
Re: Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa
« Respuesta #1 en: 9 Mayo 2016, 18:21 pm »

Hola

Buen aporte Lekim. Añadiré algunos detalles importantes a lo que has explicado:

1.
La enumeración Environment.SpecialFolder recopila muchas de las carpetas especiales o virtuales del sistema.

2.
Para quien tenga la curiosidad de saberlo:
Al usar la aplicacion Rundll32 como en este ejemplo de aquí abajo, el primer parámetro especifica el nombre de la dll, el segundo parámetro especifica el nombre de la función (tiene que ser COM visible), y el resto de parámetros son los parámetros de dicha función, donde el último parámetro en este caso especifica la página o pestaña que queremos abrir con un índice basado en cero, siendo así el valor "0" la primera página.
Código:
RunDll32.exe shell32.dll,Control_RunDLL appwiz.cpl,,0

3.
Se puede reemplazar el uso de Rundll32 por la aplicación Control para evitar tener que especificar el nombre de la dll y el nombre de la función, simplificando así el código.
De esto:
Código:
RunDll32.exe shell32.dll,Control_RunDLL appwiz.cpl,,0
A esto otro:
Código:
control.exe appwiz.cpl,,0

4.
En realidad el uso de GUIDs o CLSIDs para acceder a elementos del panel de control está deprecado, ya que a partir de Windows Vista se pueden utilizar nombres canónicos, lo que hace más legible el código y más facil de recordar.
De esto:
Código:
explorer.exe "shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{17cd9488-1228-4b2f-88ce-4298e93e0966}\pageFileAssoc"
A esto otro:
Código:
control.exe /name Microsoft.DefaultPrograms /page pageFileAssoc

Más info al respecto:

La lista completa de nombres canónicos de elementos del panel de control:

5.
En lo referente a la programación bajo la plataforma .Net Framework, usar aplicaciones externas supone desventajas en las que no quiero entrar mucho en detalle pero serían una ausencia completa de control de errores (más que el código de salida...y no siempre) y un impacto negativo en el rendimiento de nuestra aplicación (iniciar un proceso y esperar el código de salida, consume muucho tiempo de ejecución en comparación),
por ese motivo podemos y deberíamos evitar el uso de aplicaciones externas y dependientes del sistema como Explorer, RunDll32 o Control ya que en .Net podemos hacer uso directo de la API de Windows implementando la interfáz IOpenControlPanel para reemplazar la funcionalidad que deseamos de los exe mencionados anteriormente, con las ventajas que eso supone.

Estas serían las definiciones para Visual Basic.Net:

Código
  1. Friend NotInheritable Class NativeMethods
  2.  
  3.    Enum ControlPanelView As Integer
  4.        Classic = 0
  5.        Category = 1
  6.    End Enum
  7.  
  8.    <ComImport()>
  9.    <Guid("06622D85-6856-4460-8DE1-A81921B41C4B")>
  10.    Class COpenControlPanel
  11.    End Class
  12.  
  13.    <ComImport()>
  14.    <InterfaceType(ComInterfaceType.InterfaceIsIUnknown)>
  15.    <Guid("D11AD862-66DE-4DF4-BF6C-1F5621996AF1")>
  16.    Interface IOpenControlPanel
  17.  
  18.        <PreserveSig()>
  19.        Function Open(<MarshalAs(UnmanagedType.BStr)> ByVal name As String,
  20.                      <MarshalAs(UnmanagedType.BStr)> ByVal page As String,
  21.                                                      ByVal punkSite As IntPtr
  22.        ) As Integer
  23.  
  24.        <PreserveSig()>
  25.        Function GetPath(<MarshalAs(UnmanagedType.BStr)> ByVal name As String,
  26.                       <MarshalAs(UnmanagedType.LPWStr)> ByVal path As StringBuilder,
  27.                                                         ByVal bufferSize As Integer
  28.        ) As Integer
  29.  
  30.        <PreserveSig()>
  31.        Function GetCurrentView(ByRef refView As ControlPanelView
  32.        ) As Integer
  33.  
  34.    End Interface
  35.  
  36. End Class

Ejemplo de uso:
Código
  1. Dim cp As IOpenControlPanel = DirectCast(New COpenControlPanel, IOpenControlPanel)
  2. cp.Open("Microsoft.DefaultPrograms", "pageFileAssoc", Nothing)
  3. Marshal.FinalReleaseComObject(cp)

Más info al respecto:

Saludos


« Última modificación: 9 Mayo 2016, 19:36 pm por Eleкtro » En línea

Eleкtro
Ex-Staff
*
Desconectado Desconectado

Mensajes: 9.788



Ver Perfil
Re: Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa
« Respuesta #2 en: 10 Mayo 2016, 16:15 pm »

Con el uso de la interfáz Win32 que mencioné en el comentario anterior, esto sería una implementación orientada a las páginas del panel de control de Windows 10, utilizando la siguiente enumeración para hacerlo más amistoso en tiempo de diseño:

(yo escogí una Enum, pero podriamos usar un diccionario o lo que más nos guste para darle otro enfoque distinto de usabilidad al código ...claro está)

Código
  1.    Public Enum ControlPanelItems As Integer
  2.        ActionCenter
  3.        ActionCenter_ArchivedMessages
  4.        ActionCenter_AutomaticMaintenance
  5.        ActionCenter_ProblemReportingSettings
  6.        ActionCenter_ProblemReports
  7.        ActionCenter_ReliabilityMonitor
  8.        AdministrativeTools
  9.        AutoPlay
  10.        BiometricDevices
  11.        BitLockerDriveEncryption
  12.        ColorManagement
  13.        CredentialManager
  14.        CredentialManager_WindowsCredentials
  15.        DateAndTime
  16.        DateAndTime_Additionalclocks
  17.        DefaultPrograms
  18.        DefaultPrograms_SetAssociations
  19.        DefaultPrograms_SetDefaultPrograms
  20.        DeviceManager
  21.        DevicesAndPrinters
  22.        Display
  23.        Display_ScreenResolution
  24.        EaseOfAccessCenter
  25.        EaseOfAccessCenter_GetRecommendationsToMakeYourComputerEasierToUse_Cognitive
  26.        EaseOfAccessCenter_GetRecommendationsToMakeYourComputerEasierToUse_Eyesight
  27.        EaseOfAccessCenter_MakeTheComputerEasierToSee
  28.        EaseOfAccessCenter_MakeTheKeyboardEasierToUse
  29.        EaseOfAccessCenter_MakeTheMouseEasierToUse
  30.        EaseOfAccessCenter_SetUpFilterKeys
  31.        EaseOfAccessCenter_UseTextOrVisualAlternativesForSounds
  32.        EaseOfAccessCenter_UseTheComputerWithoutADisplay
  33.        EaseOfAccessCenter_UseTheComputerWithoutAMouseOrKeyboard
  34.        FamilySafety
  35.        FamilySafety_ChooseAUserAndSetUpFamilySafety
  36.        FileHistory
  37.        FolderOptions
  38.        Fonts
  39.        HomeGroup
  40.        IndexingOptions
  41.        Infrared
  42.        InternetOptions
  43.        InternetOptions_Advanced
  44.        InternetOptions_Connections
  45.        InternetOptions_Content
  46.        InternetOptions_Privacy
  47.        InternetOptions_Programs
  48.        InternetOptions_Security
  49.        ISCSIInitiator
  50.        ISNSServer
  51.        Keyboard
  52.        Language
  53.        LocationSettings
  54.        Mouse
  55.        Mouse_Hardware
  56.        Mouse_PointerOptions
  57.        Mouse_Pointers
  58.        Mouse_Wheel
  59.        MPIOConfiguration
  60.        NetworkAndSharingCenter
  61.        NetworkAndSharingCenter_AdvancedSharingSettings
  62.        NetworkAndSharingCenter_MediaStreamingOptions
  63.        NotificationAreaIcons
  64.        PenAndTouch
  65.        PenAndTouch_Flicks
  66.        PenAndTouch_Handwriting
  67.        Personalization
  68.        Personalization_ColorAndAppearance
  69.        Personalization_DesktopBackground
  70.        PhoneAndModem
  71.        PowerOptions
  72.        PowerOptions_EditPlanSettings
  73.        PowerOptions_SystemSettings
  74.        ProgramsAndFeatures
  75.        ProgramsAndFeatures_InstalledUpdates
  76.        Recovery
  77.        Region
  78.        Region_Administrative
  79.        Region_Location
  80.        RemoteAppAndDesktopConnections
  81.        Sound
  82.        SpeechRecognition
  83.        StorageSpaces
  84.        SyncCenter
  85.        System
  86.        TabletPCSettings
  87.        TaskbarAndNavigation
  88.        Troubleshooting
  89.        Troubleshooting_History
  90.        TSAppInstall
  91.        UserAccounts
  92.        WindowsAnytimeUpgrade
  93.        WindowsDefender
  94.        WindowsFirewall
  95.        WindowsFirewall_AllowedApps
  96.        WindowsMobilityCenter
  97.        WindowsToGo
  98.        WindowsUpdate
  99.        WindowsUpdate_ChangeSettings
  100.        WindowsUpdate_ViewUpdateHistory
  101.        WorkFolders
  102.    End Enum

Ahora solo debemos crear un método como este de aquí abajo donde controlar el valor de la enumeración que le pasemos a dicho método:

Código
  1.    Public NotInheritable Class ControlPanelUtil
  2.  
  3.        <DebuggerNonUserCode>
  4.        Private Sub New()
  5.        End Sub
  6.  
  7.        ''' <summary>
  8.        ''' Opens the Control Panel.
  9.        ''' </summary>
  10.        <DebuggerStepThrough>
  11.        Public Shared Sub Open()
  12.            ControlPanel.OpenControlPanelItem(Nothing, Nothing)
  13.        End Sub
  14.  
  15.        ''' <summary>
  16.        ''' Opens a Control Panel Item.
  17.        ''' </summary>
  18.        <DebuggerStepThrough>
  19.        Public Shared Sub Open(ByVal item As ControlPanelItems)
  20.  
  21.            Select Case item
  22.  
  23.                Case ControlPanelItems.ActionCenter
  24.                    ControlPanel.OpenControlPanelItem("Microsoft.ActionCenter", Nothing)
  25.  
  26.                Case ControlPanelItems.ActionCenter_ArchivedMessages
  27.                    ControlPanel.OpenControlPanelItem("Microsoft.ActionCenter", "pageResponseArchive")
  28.  
  29.                Case ControlPanelItems.ActionCenter_AutomaticMaintenance
  30.                    ControlPanel.OpenControlPanelItem("Microsoft.ActionCenter", "MaintenanceSettings")
  31.  
  32.                Case ControlPanelItems.ActionCenter_ProblemReportingSettings
  33.                    ControlPanel.OpenControlPanelItem("Microsoft.ActionCenter", "pageSettings")
  34.  
  35.                Case ControlPanelItems.ActionCenter_ProblemReports
  36.                    ControlPanel.OpenControlPanelItem("Microsoft.ActionCenter", "pageProblems")
  37.  
  38.                Case ControlPanelItems.ActionCenter_ReliabilityMonitor
  39.                    ControlPanel.OpenControlPanelItem("Microsoft.ActionCenter", "pageReliabilityView")
  40.  
  41.                Case ControlPanelItems.AdministrativeTools
  42.                    ControlPanel.OpenControlPanelItem("Microsoft.AdministrativeTools", Nothing)
  43.  
  44.                Case ControlPanelItems.AutoPlay
  45.                    ControlPanel.OpenControlPanelItem("Microsoft.AutoPlay", Nothing)
  46.  
  47.                Case ControlPanelItems.BiometricDevices
  48.                    ControlPanel.OpenControlPanelItem("Microsoft.BiometricDevices", Nothing)
  49.  
  50.                Case ControlPanelItems.BitLockerDriveEncryption
  51.                    ControlPanel.OpenControlPanelItem("Microsoft.BitLockerDriveEncryption", Nothing)
  52.  
  53.                Case ControlPanelItems.ColorManagement
  54.                    ControlPanel.OpenControlPanelItem("Microsoft.ColorManagement", Nothing)
  55.  
  56.                Case ControlPanelItems.CredentialManager
  57.                    ControlPanel.OpenControlPanelItem("Microsoft.CredentialManager", Nothing)
  58.  
  59.                Case ControlPanelItems.CredentialManager_WindowsCredentials
  60.                    ControlPanel.OpenControlPanelItem("Microsoft.CredentialManager", "?SelectedVault=CredmanVault")
  61.  
  62.                Case ControlPanelItems.DateAndTime
  63.                    ControlPanel.OpenControlPanelItem("Microsoft.DateAndTime", Nothing)
  64.  
  65.                Case ControlPanelItems.DateAndTime_Additionalclocks
  66.                    ControlPanel.OpenControlPanelItem("Microsoft.DateAndTime", "1")
  67.  
  68.                Case ControlPanelItems.DefaultPrograms
  69.                    ControlPanel.OpenControlPanelItem("Microsoft.DefaultPrograms", Nothing)
  70.  
  71.                Case ControlPanelItems.DefaultPrograms_SetAssociations
  72.                    ControlPanel.OpenControlPanelItem("Microsoft.DefaultPrograms", "pageFileAssoc")
  73.  
  74.                Case ControlPanelItems.DefaultPrograms_SetDefaultPrograms
  75.                    ControlPanel.OpenControlPanelItem("Microsoft.DefaultPrograms", "pageDefaultProgram")
  76.  
  77.                Case ControlPanelItems.DeviceManager
  78.                    ControlPanel.OpenControlPanelItem("Microsoft.DeviceManager", Nothing)
  79.  
  80.                Case ControlPanelItems.DevicesAndPrinters
  81.                    ControlPanel.OpenControlPanelItem("Microsoft.DevicesAndPrinters", Nothing)
  82.  
  83.                Case ControlPanelItems.Display
  84.                    ControlPanel.OpenControlPanelItem("Microsoft.Display", Nothing)
  85.  
  86.                Case ControlPanelItems.Display_ScreenResolution
  87.                    ControlPanel.OpenControlPanelItem("Microsoft.Display", "Settings")
  88.  
  89.                Case ControlPanelItems.EaseOfAccessCenter
  90.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", Nothing)
  91.  
  92.                Case ControlPanelItems.EaseOfAccessCenter_GetRecommendationsToMakeYourComputerEasierToUse_Cognitive
  93.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageQuestionsCognitive")
  94.  
  95.                Case ControlPanelItems.EaseOfAccessCenter_GetRecommendationsToMakeYourComputerEasierToUse_Eyesight
  96.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageQuestionsEyesight")
  97.  
  98.                Case ControlPanelItems.EaseOfAccessCenter_MakeTheComputerEasierToSee
  99.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageEasierToSee")
  100.  
  101.                Case ControlPanelItems.EaseOfAccessCenter_MakeTheKeyboardEasierToUse
  102.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageKeyboardEasierToUse")
  103.  
  104.                Case ControlPanelItems.EaseOfAccessCenter_MakeTheMouseEasierToUse
  105.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageEasierToClick")
  106.  
  107.                Case ControlPanelItems.EaseOfAccessCenter_SetUpFilterKeys
  108.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageFilterKeysSettings")
  109.  
  110.                Case ControlPanelItems.EaseOfAccessCenter_UseTextOrVisualAlternativesForSounds
  111.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageEasierWithSounds")
  112.  
  113.                Case ControlPanelItems.EaseOfAccessCenter_UseTheComputerWithoutADisplay
  114.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageNoVisual")
  115.  
  116.                Case ControlPanelItems.EaseOfAccessCenter_UseTheComputerWithoutAMouseOrKeyboard
  117.                    ControlPanel.OpenControlPanelItem("Microsoft.EaseOfAccessCenter", "pageNoMouseOrKeyboard")
  118.  
  119.                Case ControlPanelItems.FamilySafety
  120.                    ControlPanel.OpenControlPanelItem("Microsoft.ParentalControls", Nothing)
  121.  
  122.                Case ControlPanelItems.FamilySafety_ChooseAUserAndSetUpFamilySafety
  123.                    ControlPanel.OpenControlPanelItem("Microsoft.ParentalControls", "pageUserHub")
  124.  
  125.                Case ControlPanelItems.FileHistory
  126.                    ControlPanel.OpenControlPanelItem("Microsoft.FileHistory", Nothing)
  127.  
  128.                Case ControlPanelItems.FolderOptions
  129.                    ControlPanel.OpenControlPanelItem("Microsoft.FolderOptions", Nothing)
  130.  
  131.                Case ControlPanelItems.Fonts
  132.                    ControlPanel.OpenControlPanelItem("Microsoft.Fonts", Nothing)
  133.  
  134.                Case ControlPanelItems.HomeGroup
  135.                    ControlPanel.OpenControlPanelItem("Microsoft.HomeGroup", Nothing)
  136.  
  137.                Case ControlPanelItems.IndexingOptions
  138.                    ControlPanel.OpenControlPanelItem("Microsoft.IndexingOptions", Nothing)
  139.  
  140.                Case ControlPanelItems.Infrared
  141.                    ControlPanel.OpenControlPanelItem("Microsoft.Infrared", Nothing)
  142.  
  143.                Case ControlPanelItems.InternetOptions
  144.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", Nothing)
  145.  
  146.                Case ControlPanelItems.InternetOptions_Advanced
  147.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", "6")
  148.  
  149.                Case ControlPanelItems.InternetOptions_Connections
  150.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", "4")
  151.  
  152.                Case ControlPanelItems.InternetOptions_Content
  153.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", "3")
  154.  
  155.                Case ControlPanelItems.InternetOptions_Privacy
  156.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", "2")
  157.  
  158.                Case ControlPanelItems.InternetOptions_Programs
  159.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", "5")
  160.  
  161.                Case ControlPanelItems.InternetOptions_Security
  162.                    ControlPanel.OpenControlPanelItem("Microsoft.InternetOptions", "1")
  163.  
  164.                Case ControlPanelItems.ISCSIInitiator
  165.                    ControlPanel.OpenControlPanelItem("Microsoft.iSCSIInitiator", Nothing)
  166.  
  167.                Case ControlPanelItems.ISNSServer
  168.                    ControlPanel.OpenControlPanelItem("Microsoft.iSNSServer", Nothing)
  169.  
  170.                Case ControlPanelItems.Keyboard
  171.                    ControlPanel.OpenControlPanelItem("Microsoft.Keyboard", Nothing)
  172.  
  173.                Case ControlPanelItems.Language
  174.                    ControlPanel.OpenControlPanelItem("Microsoft.Language", Nothing)
  175.  
  176.                Case ControlPanelItems.LocationSettings
  177.                    ControlPanel.OpenControlPanelItem("Microsoft.LocationSettings", Nothing)
  178.  
  179.                Case ControlPanelItems.Mouse
  180.                    ControlPanel.OpenControlPanelItem("Microsoft.Mouse", Nothing)
  181.  
  182.                Case ControlPanelItems.Mouse_Hardware
  183.                    ControlPanel.OpenControlPanelItem("Microsoft.Mouse", "4")
  184.  
  185.                Case ControlPanelItems.Mouse_PointerOptions
  186.                    ControlPanel.OpenControlPanelItem("Microsoft.Mouse", "2")
  187.  
  188.                Case ControlPanelItems.Mouse_Pointers
  189.                    ControlPanel.OpenControlPanelItem("Microsoft.Mouse", "1")
  190.  
  191.                Case ControlPanelItems.Mouse_Wheel
  192.                    ControlPanel.OpenControlPanelItem("Microsoft.Mouse", "3")
  193.  
  194.                Case ControlPanelItems.MPIOConfiguration
  195.                    ControlPanel.OpenControlPanelItem("Microsoft.MPIOConfiguration", Nothing)
  196.  
  197.                Case ControlPanelItems.NetworkAndSharingCenter
  198.                    ControlPanel.OpenControlPanelItem("Microsoft.NetworkAndSharingCenter", Nothing)
  199.  
  200.                Case ControlPanelItems.NetworkAndSharingCenter_AdvancedSharingSettings
  201.                    ControlPanel.OpenControlPanelItem("Microsoft.NetworkAndSharingCenter", "Advanced")
  202.  
  203.                Case ControlPanelItems.NetworkAndSharingCenter_MediaStreamingOptions
  204.                    ControlPanel.OpenControlPanelItem("Microsoft.NetworkAndSharingCenter", "ShareMedia")
  205.  
  206.                Case ControlPanelItems.NotificationAreaIcons
  207.                    ControlPanel.OpenControlPanelItem("Microsoft.NotificationAreaIcons", Nothing)
  208.  
  209.                Case ControlPanelItems.PenAndTouch
  210.                    ControlPanel.OpenControlPanelItem("Microsoft.PenAndTouch", Nothing)
  211.  
  212.                Case ControlPanelItems.PenAndTouch_Flicks
  213.                    ControlPanel.OpenControlPanelItem("Microsoft.PenAndTouch", "1")
  214.  
  215.                Case ControlPanelItems.PenAndTouch_Handwriting
  216.                    ControlPanel.OpenControlPanelItem("Microsoft.PenAndTouch", "2")
  217.  
  218.                Case ControlPanelItems.Personalization
  219.                    ControlPanel.OpenControlPanelItem("Microsoft.Personalization", Nothing)
  220.  
  221.                Case ControlPanelItems.Personalization_ColorAndAppearance
  222.                    ControlPanel.OpenControlPanelItem("Microsoft.Personalization", "pageColorization")
  223.  
  224.                Case ControlPanelItems.Personalization_DesktopBackground
  225.                    ControlPanel.OpenControlPanelItem("Microsoft.Personalization", "pageWallpaper")
  226.  
  227.                Case ControlPanelItems.PhoneAndModem
  228.                    ControlPanel.OpenControlPanelItem("Microsoft.PhoneAndModem", Nothing)
  229.  
  230.                Case ControlPanelItems.PowerOptions
  231.                    ControlPanel.OpenControlPanelItem("Microsoft.PowerOptions", Nothing)
  232.  
  233.                Case ControlPanelItems.PowerOptions_EditPlanSettings
  234.                    ControlPanel.OpenControlPanelItem("Microsoft.PowerOptions", "pagePlanSettings")
  235.  
  236.                Case ControlPanelItems.PowerOptions_SystemSettings
  237.                    ControlPanel.OpenControlPanelItem("Microsoft.PowerOptions", "pageGlobalSettings")
  238.  
  239.                Case ControlPanelItems.ProgramsAndFeatures
  240.                    ControlPanel.OpenControlPanelItem("Microsoft.ProgramsAndFeatures", Nothing)
  241.  
  242.                Case ControlPanelItems.ProgramsAndFeatures_InstalledUpdates
  243.                    ControlPanel.OpenControlPanelItem("Microsoft.ProgramsAndFeatures", "::{D450A8A1-9568-45C7-9C0E-B4F9FB4537BD}")
  244.  
  245.                Case ControlPanelItems.Recovery
  246.                    ControlPanel.OpenControlPanelItem("Microsoft.Recovery", Nothing)
  247.  
  248.                Case ControlPanelItems.Region
  249.                    ControlPanel.OpenControlPanelItem("Microsoft.RegionAndLanguage", Nothing)
  250.  
  251.                Case ControlPanelItems.Region_Administrative
  252.                    ControlPanel.OpenControlPanelItem("Microsoft.RegionAndLanguage", "2")
  253.  
  254.                Case ControlPanelItems.Region_Location
  255.                    ControlPanel.OpenControlPanelItem("Microsoft.RegionAndLanguage", "1")
  256.  
  257.                Case ControlPanelItems.RemoteAppAndDesktopConnections
  258.                    ControlPanel.OpenControlPanelItem("Microsoft.RemoteAppAndDesktopConnections", Nothing)
  259.  
  260.                Case ControlPanelItems.Sound
  261.                    ControlPanel.OpenControlPanelItem("Microsoft.Sound", Nothing)
  262.  
  263.                Case ControlPanelItems.SpeechRecognition
  264.                    ControlPanel.OpenControlPanelItem("Microsoft.SpeechRecognition", Nothing)
  265.  
  266.                Case ControlPanelItems.StorageSpaces
  267.                    ControlPanel.OpenControlPanelItem("Microsoft.StorageSpaces", Nothing)
  268.  
  269.                Case ControlPanelItems.SyncCenter
  270.                    ControlPanel.OpenControlPanelItem("Microsoft.SyncCenter", Nothing)
  271.  
  272.                Case ControlPanelItems.System
  273.                    ControlPanel.OpenControlPanelItem("Microsoft.System", Nothing)
  274.  
  275.                Case ControlPanelItems.TabletPCSettings
  276.                    ControlPanel.OpenControlPanelItem("Microsoft.TabletPCSettings", Nothing)
  277.  
  278.                Case ControlPanelItems.TaskbarAndNavigation
  279.                    ControlPanel.OpenControlPanelItem("Microsoft.Taskbar", Nothing)
  280.  
  281.                Case ControlPanelItems.Troubleshooting
  282.                    ControlPanel.OpenControlPanelItem("Microsoft.Troubleshooting", Nothing)
  283.  
  284.                Case ControlPanelItems.Troubleshooting_History
  285.                    ControlPanel.OpenControlPanelItem("Microsoft.Troubleshooting", "HistoryPage")
  286.  
  287.                Case ControlPanelItems.TSAppInstall
  288.                    ControlPanel.OpenControlPanelItem("Microsoft.TSAppInstall", Nothing)
  289.  
  290.                Case ControlPanelItems.UserAccounts
  291.                    ControlPanel.OpenControlPanelItem("Microsoft.UserAccounts", Nothing)
  292.  
  293.                Case ControlPanelItems.WindowsAnytimeUpgrade
  294.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsAnytimeUpgrade", Nothing)
  295.  
  296.                Case ControlPanelItems.WindowsDefender
  297.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsDefender", Nothing)
  298.  
  299.                Case ControlPanelItems.WindowsFirewall
  300.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsFirewall", Nothing)
  301.  
  302.                Case ControlPanelItems.WindowsFirewall_AllowedApps
  303.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsFirewall", "pageConfigureApps")
  304.  
  305.                Case ControlPanelItems.WindowsMobilityCenter
  306.                    ControlPanel.OpenControlPanelItem("Microsoft.MobilityCenter", Nothing)
  307.  
  308.                Case ControlPanelItems.WindowsToGo
  309.                    ControlPanel.OpenControlPanelItem("Microsoft.PortableWorkspaceCreator", Nothing)
  310.  
  311.                Case ControlPanelItems.WindowsUpdate
  312.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsUpdate", Nothing)
  313.  
  314.                Case ControlPanelItems.WindowsUpdate_ChangeSettings
  315.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsUpdate", "pageSettings")
  316.  
  317.                Case ControlPanelItems.WindowsUpdate_ViewUpdateHistory
  318.                    ControlPanel.OpenControlPanelItem("Microsoft.WindowsUpdate", "pageUpdateHistory")
  319.  
  320.                Case ControlPanelItems.WorkFolders
  321.                    ControlPanel.OpenControlPanelItem("Microsoft.WorkFolders", Nothing)
  322.  
  323.                Case Else
  324.                    Throw New InvalidEnumArgumentException(argumentName:="item",
  325.                                                           invalidValue:=item,
  326.                                                           enumClass:=GetType(ControlPanelItems))
  327.  
  328.            End Select
  329.  
  330.        End Sub
  331.  
  332.        <DebuggerStepThrough>
  333.        Private Shared Sub OpenControlPanelItem(ByVal name As String,
  334.                                                ByVal page As String)
  335.  
  336.            Dim cp As IOpenControlPanel = DirectCast(New OpenControlPanel, IOpenControlPanel)
  337.            cp.Open(name, page, Nothing)
  338.            Marshal.FinalReleaseComObject(cp)
  339.  
  340.        End Sub
  341.  
  342.    End Class

Actualmente todo esto y mucho más forma parte de mi API gratuita conocida como ElektroKit, que pueden encontrar en GitHub por ese mismo nombre.

Créditos: Elektro (y MSDN :P).

Saludos
« Última modificación: 10 Mayo 2016, 16:48 pm por Eleкtro » En línea

Lekim

Desconectado Desconectado

Mensajes: 268



Ver Perfil
Re: Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa
« Respuesta #3 en: 11 Mayo 2016, 18:11 pm »

Gracias Elektro por ampliar el tema.  ;-)

Ayer me instalé Windows 7 en el PC ( en el portátil tengo Vista), y comprobé el archivo Shell32.dll, y como dices después de Vista, ya no se encuentra las llamadas... :
Código:
shell:::{26EE0668-A00A-44D7-9371-BEB064C98683}\8\::{15EAE92E-F17A-4431-9F28-805E482dAFD4}

... en Shell32.dll pero siguen funcionando y se pueden usar tranquilamente en Windows 7 sin problemas. A no ser que se haga una llamada a algo que simplemente ya no exista o se deba hacer de otra manera.

Aunque alguna queda, por ejemplo, se puede encontrar esta parte del recurso XML en Shell32.dll de W7 que corresponde a 'Panel de control\Programas\Obtener programas':

Código
  1. ....
  2. <sh:name>@shell32.dll,-24109</sh:name>
  3. <sh:keywords>@shell32.dll,-25334</sh:keywords>
  4. <sh:keywords>@shell32.dll,-25207</sh:keywords>
  5. <sh:keywords>@shell32.dll,-25077</sh:keywords>
  6. <sh:command>esh:command>
  7. <sh:condition name="shcond://v1#IsMachineOnDomain"/>
  8. </sh:conditions>
  9. ....



Ahora la mayoría es como esto:
Código
  1. ....
  2. <sh:name>@shell32.dll,-24078</sh:name>
  3. <sh:keywords>@shell32.dll,-25068</sh:keywords>
  4. <sh:keywords>@shell32.dll,-25067</sh:keywords>
  5. <sh:keywords>@shell32.dll,-25092</sh:keywords>
  6. <sh:keywords>@shell32.dll,-25069</sh:keywords>
  7. <sh2:controlpanel page="pageEasierToSee" name="Microsoft.EaseOfAccessCenter"/>
  8. ...


Me has ahorrado también listar todas las entradas y el código para usar en NET.  ;-)

Aunque si te digo la verdad no me lo esperaba, ya tenía escrito y me encuentro que ya lo habías puesto tú e incluso mejor.


Permíteme ahora, algunas consideraciones, que creo no están fuera de lugar.

En realidad el uso de GUIDs o CLSIDs para acceder a elementos del panel de control está deprecado, ya que a partir de Windows Vista se pueden utilizar nombres canónicos, lo que hace más legible el código y más fácil de recordar.

Desde mi punto de vista en informática no existe nada "deprecado" (luego explico porqué lo pongo entre comillas). Es como decir que las máquinas de escribir ya no se usan. Todavía hay gente que las usa. Al final todo depende de gustos y necesidades, y no del hecho que haya surgido algo más nuevo dentro del cual lo de antes ya no se use. Yo no voy a tirar ni dejar de usar mi vieja máquina de escribir porque ya no se use o porque ahora tenga un ordenador. Puede que en algún momento la necesite y me venga la mar de bien.

Si nunca hubiera existido Windows XP y surgiera ahora ¿Podría considerarse obsoleto algo de Vista o W7, W8, etc, porque no funcione o no se use en XP? Además, si algo sigue pudiéndose usar, ya sea dentro de lo nuevo o lo viejo o ambos, no puede considerarse obsoleto. Si por ejemplo, Microsoft incluye y permite usar funciones VB, quien las quiera usar que las use, tampoco va a explotar el ordenador y para alguna chapucilla para qué complicarse.

Permíteme un pequeño apunte y que valga para los demás. Creo que abusas de la palabra "deprecado" ya que te lo he visto usar muchas  veces. No estoy seguro que signifique lo que imaginas, ¿anticuado, desusado, viejo, arcaico, antiguo, desfasado, caduco, obsoleto?  

En inglés, deprecated significa obsoleto o censurado, pero en castellano he buscado y significa algo muy distinto como rogar o suplicar. No he encontrado ninguna acepción similar a 'obsoleto', en lengua castellana, que supongo es la que quieres usar en realidad o similar. Como no sea en algún país latino.

Código:
deprecar. (Del lat. deprecāri, rogar). tr. Rogar, pedir, suplicar con eficacia o instancia.



y un impacto negativo en el rendimiento de nuestra aplicación (iniciar un proceso y esperar el código de salida, consume mucho tiempo de ejecución en comparación)

¿Qué computadora usas tú? Tanto como 'muucho tiempo' es exagerar. Yo no uso digamos una super computadora de la NASA, me considero una persona impaciente y a mí se me carga al instante aunque use Explorer.exe o Rundll32. En fin.

Espero no te tomes estos comentarios como una reprimenda después de todo, tu también a veces lo haces XD


S2s
« Última modificación: 11 Mayo 2016, 18:16 pm por Lekim » En línea

Eleкtro
Ex-Staff
*
Desconectado Desconectado

Mensajes: 9.788



Ver Perfil
Re: Abrir ventanas y cuadros de diálogo especiales de Windows desde nuestro programa
« Respuesta #4 en: 11 Mayo 2016, 22:44 pm »

Desde mi punto de vista en informática no existe nada "deprecado"

Eso es muy discutible, aunque cada persona puede interpretarlo como prefiera, pero lo que podemos ver es que en la vida, en la tecnología, y más concretamente en la informática, la utilización de lo deprecado tiende a traer consecuencias negativas (aparte de no estar aprovechando lo moderno/completo), como por ejemplo la ausencia de soporte y compatibilidad de lo que está deprecado, o que desaparezca por completo, cosa que también ocurre en la programación (si, las funciones deprecadas tienden a ser eliminadas con el paso de los años).

Sin ir más lejos te daré unos ejemplos que conoces de sobra:
  • Sistemas operativos como Windows XP y anteriores.
  • IDEs como Visual Studio 2010 y etc (que no soportan los nuevos runtimes de .Net Framework).
  • Visual Basic 5, 6, y etc.
  • La tecnología Windows Forms.
  • Los primeros runtimes de .NET Framework.

En lo que respecta al uso de funciones deprecadas en la API de Windows, cuando se le asigna el estado "deprecado", éstas tienden a desaparecer por completo con el tiempo como ya he mencionado, aunque comúnmente pasan a ser completamente reemplazadas por otras funciones más modernas, más completas, y en constante refactorización, mientras que esa función deprecada sigue permaneciendo ahí simplemente por compatibilidad y sin aportar ninguna mejora/refactorización en su código en el futuro, como por ejemplo la función WinExec. Como ya te digo, no es que yo me lo invente, también puedes leer lo que acabo de explicar, en la Wikipedia:

En resumen, lo obsolescente está condenado a la extinción por que la obsolescencia implica un olvido con el paso del tiempo, al menos así lo veo yo.



Creo que abusas de la palabra "deprecado" ya que te lo he visto usar muchas  veces.

Te equivocas, no creo que se pueda considerar abuso cuando la información que se da es la correcta para abrir camino hacia el uso de metodologías modernas.

Cuando me hayas visto decir que una función u otro tipo de miembro y/o conjunto o metodología está deprecada, jamás ni una sola vez lo he dicho como una simple opinión personal mia, sino como una información que está expuesta en los artículos de MSDN (o por desarrolladores de Microsoft en otros artículos, etc, vamos, cosas oficiales), no es que yo lo diga por que me de la gana, solamente transmito lo que afirma Microsoft con ese mismo termino "deprecated" ...seguido de un vínculo que redirige a una función y/o metodología mejorada, como suele ser, y como es el caso.



Citar
No estoy seguro que signifique lo que imaginas, ¿anticuado, desusado, viejo, arcaico, antiguo, desfasado, caduco, obsoleto?  

En inglés, deprecated significa obsoleto o censurado, pero en castellano he buscado y significa algo muy distinto como rogar o suplicar.

Vaya, ahí si que te tengo que dar toda la razón del mundo, he estado utilizando mal esa palabra todo este tiempo.

No me gusta decir que algo es obsoleto, no me gusta lo despectiva que suena esa palabra y por eso empecé a usar la palabra "deprecado" (dándole un significado incorrecto como has explicado) como sinónimo de anticuado, desfasado o ...si, obsoleto.



Citar
y un impacto negativo en el rendimiento de nuestra aplicación (iniciar un proceso y esperar el código de salida, consume mucho tiempo de ejecución en comparación)

Citar
¿Qué computadora usas tú? Tanto como 'muucho tiempo' es exagerar. Yo no uso digamos una super computadora de la NASA, me considero una persona impaciente y a mí se me carga al instante aunque use Explorer.exe o Rundll32. En fin.

Que tu tengas la sensación de que se "cargue" al instante no significa que no exista una diferencia de velocidad por los procedimientos necesarios que supone crear un proceso y destuirlo. También se debe leer entre lineas cuando he dicho "es mucho EN COMPARACIÓN", eso en la mayoría de casos significa muy pocos millisegundos, no más, pero eso se puede considerar como una diferencia muy excesiva cuando se busca la perfección o eficiencia máxima posible de un algoritmo, por que esas pequeñas cosas (como por ejemplo búcles repetitivos que inicien executables para esperar un código de salida) son lo que al final lo acaban haciendo expensivo.



Citar
Espero no te tomes estos comentarios como una reprimenda después de todo, tu también a veces lo haces XD

Si yo no estuviese abierto a las críticas negativas entonces no me consideraría moderador, y es cierto que yo a veces intento corregir a quien me parece o a quien estoy seguro de que se equivoca pero más que por corregirle es por enseñarle a esa persona, en cambio, me parece que tu en más de un comentario de este post has utilizado un sarcasmo extremo que no viene a cuento ...debido a ideas equívocas;
si no estás seguro de la veracidad de algo de lo que yo te diga, pues tal vez lo correcto sería preguntarme por que motivos afirmo esas cosas en vez de intentar corregir, o informarte por ti mismo para poder tener argumentos con los que debatirlo, y entonces yo aceptaría una posible corrección si hubiese que aceptarla.

Saludos!
« Última modificación: 11 Mayo 2016, 23:49 pm por Eleкtro » En línea

Páginas: [1] Ir Arriba Respuesta Imprimir 

Ir a:  

WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines