Controlling Windows Regional Settings From Vba
VBA controlling IE confirmation popup box
VBA to open control panel's "Internet Date & Time" applet
VBA: How To: Floating VBA Control Panel for Initialization
Panel Class
Controlling Windows Regional Settings from VBA
controlling IE using vba from within a worksheet additional info
Controlling external programs using vba
VBA controlling Acrobat Distiller
Agora, quero fazer uma abordagem distinta, por usar o comendo SHELL.
Para chamar qualquer tela do Painel de Controle não precisamos necessariamente evocar uma API
'Para chamar a tela principal do Painel de Controle:Call Shell("rundll32.exe shell32.dll,Control_RunDLL", vbNormalFocus)'Para chamar a tela Adicionar ou Remover Programas:Call Shell("rundll32.exe shell32.dll,Control_RunDLL appwiz.cpl,,1", vbNormalFocus)'Para chamar a tela Adicionar ou Remover Programas, na aba'Instalao do Windows:Call Shell("rundll32.exe shell32.dll,Control_RunDLL appwiz.cpl,,2", vbNormalFocus)'Para chamar a tela Adicionar ou Remover Programas, na aba'Disco de Inicializao:Call Shell("rundll32.exe shell32.dll,Control_RunDLL appwiz.cpl,,3", vbNormalFocus)'Para chamar a tela Vdeo, na aba Segundo Plano:Call Shell("rundll32.exe shell32.dll,Control_RunDLL desk.cpl,,0", vbNormalFocus)'Para chamar a tela Vdeo, na aba Proteo de Tela:Call Shell("rundll32.exe shell32.dll,Control_RunDLL desk.cpl,,1", vbNormalFocus)'Para chamar a tela Vdeo, na aba Aparncia:Call Shell("rundll32.exe shell32.dll,Control_RunDLL desk.cpl,,2", vbNormalFocus)'Para chamar a tela Vdeo, na aba Configurao:Call Shell("rundll32.exe shell32.dll,Control_RunDLL desk.cpl,,3", vbNormalFocus)'Para chamar a tela Configuraes Regionais, na aba'Configuraes Regionais:Call Shell("rundll32.exe shell32.dll,Control_RunDLL intl.cpl,,0", vbNormalFocus)'Para chamar a tela Configuraes Regionais, na aba'Nmero:Call Shell("rundll32.exe shell32.dll,Control_RunDLL intl.cpl,,1", vbNormalFocus)'Para chamar a tela Configuraes Regionais, na aba'Moeda:Call Shell("rundll32.exe shell32.dll,Control_RunDLL intl.cpl,,2", vbNormalFocus)'Para chamar a tela Configuraes Regionais, na aba'Hora:Call Shell("rundll32.exe shell32.dll,Control_RunDLL intl.cpl,,3", vbNormalFocus)'Para chamar a tela Configuraes Regionais, na aba'Data:Call Shell("rundll32.exe shell32.dll,Control_RunDLL intl.cpl,,4", vbNormalFocus)'Para chamar a tela Joystick:Call Shell("rundll32.exe shell32.dll,Control_RunDLL joy.cpl", vbNormalFocus)'Para chamar a tela Mouse:Call Shell("rundll32.exe shell32.dll,Control_RunDLL main.cpl @0", vbNormalFocus)'Para chamar a tela Teclado:Call Shell("rundll32.exe shell32.dll,Control_RunDLL main.cpl @1", vbNormalFocus)'Para chamar a tela Impressoras:Call Shell("rundll32.exe shell32.dll,Control_RunDLL main.cpl @2", vbNormalFocus)'Para chamar a tela Fontes:Call Shell("rundll32.exe shell32.dll,Control_RunDLL main.cpl @3", vbNormalFocus)'Para chamar a tela Mail e Fax:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mlcfg32.cpl", vbNormalFocus)'Para chamar a tela Multimdia, na aba Audio:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mmsys.cpl,,0", vbNormalFocus)'Para chamar a tela Multimdia, na aba Vdeo:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mmsys.cpl,,1", vbNormalFocus)'Para chamar a tela Multimdia, na aba MIDI:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mmsys.cpl,,2", vbNormalFocus)'Para chamar a tela Multimdia, na aba Msica de CD:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mmsys.cpl,,3", vbNormalFocus)'Para chamar a tela Multimdia, na aba Dispositivos:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mmsys.cpl,,4", vbNormalFocus)'Para chamar a tela Som:Call Shell("rundll32.exe shell32.dll,Control_RunDLL mmsys.cpl @1", vbNormalFocus)'Para chamar a tela Modem:Call Shell("rundll32.exe shell32.dll,Control_RunDLL modem.cpl", vbNormalFocus)'Para chamar a tela Rede:Call Shell("rundll32.exe shell32.dll,Control_RunDLL netcpl.cpl", vbNormalFocus)'Para chamar a tela Senhas:Call Shell("rundll32.exe shell32.dll,Control_RunDLL password.cpl", vbNormalFocus)'Para chamar a tela Sistema, na aba Geral:Call Shell("rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl,,0", vbNormalFocus)'Para chamar a tela Sistema, na aba Gerenciador'de Dispositivos:Call Shell("rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl,,1", vbNormalFocus)'Para chamar a tela Sistema, na aba Perfis deHardware:Call Shell("rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl,,2", vbNormalFocus)'Para chamar a tela Sistema, na aba Performance:Call Shell("rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl,,3", vbNormalFocus)'Para chamar a tela Opes de Acessibilidade, na aba'Teclado:Call Shell("rundll32.exe shell32.dll,Control_RunDLL access.cpl,,1", vbNormalFocus)'Para chamar a tela Opes de Acessibilidade, na aba'Som:Call Shell("rundll32.exe shell32.dll,Control_RunDLL access.cpl,,2", vbNormalFocus)'Para chamar a tela Opes de Acessibilidade, na aba'Vdeo:Call Shell("rundll32.exe shell32.dll,Control_RunDLL access.cpl,,3", vbNormalFocus)'Para chamar a tela Opções de Acessibilidade, na aba'Mouse:Call Shell("rundll32.exe shell32.dll,Control_RunDLL access.cpl,,4", vbNormalFocus)'Para chamar a tela Opes de Acessibilidade, na aba'Geral:Call Shell("rundll32.exe shell32.dll,Control_RunDLL access.cpl,,5", vbNormalFocus)'Para chamar a tela do Assistente (Adicionar novo'Hardware):Call Shell("rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl @1", vbNormalFocus)'Para chamar a tela Data e Hora:Call Shell("rundll32.exe shell32.dll,Control_RunDLL timedate.cpl", vbNormalFocus)'Para chamar a tela DiskCopy:Call Shell("rundll32 diskcopy.dll,DiskCopyRunDll", vbNormalFocus)
Tags: Bernardes, VBA, Office, SHELL, API, rundll32.exe, Painel de Controle, Control Painel,
Nenhum comentário:
Postar um comentário