Contido

# Función Shell

Inicia outro aplicativo e se é necesario define o estilo de xanela correspondente.

### Sintaxe:

Shell (Pathname As String[, Windowstyle As Integer[, Param As String[, bSync]]])

### Parámetros:

### NomeCamiño

Name of the program that you want to start, optionally with complete path and/or arguments.

### Estiloxanela

Optional integer expression that specifies the style of the window that the program is executed in.

Parameter Windowstyle is only effective on Windows systems. On other systems the parameter is ignored.

The following values are possible:

Windowstyle | Meaning
--- | ---
0 | Está enfocada a xanela oculta do programa. Not implemented in LibreOffice.
1 | Está enfocada a xanela do programa en tamaño estándar. Not implemented in LibreOffice.
2 | Está enfocada a xanela minimizada do programa.
3 | Está enfocada a xanela maximizada do programa.
4 | Xanela de programa de tamaño estándar, sen foco. Not implemented in LibreOffice.
6 | Xanela de programa minimizada; segue enfocada a xanela activa. Not implemented in LibreOffice.
10 | Visualización en pantalla completa.

Windowstyle 3 and 10 are equivalent in Windows systems.

### Parám

String that specifies additional arguments passed to the program.

### bSync

If this value is set to true, the Shell command and all LibreOffice tasks wait until the shell process completes. If the value is set to false, the shell returns directly. The default value is false.

### Códigos de erro

5 Chamada de procedemento incorrecta

53 Ficheiro non atopado

73 Non implementado

### Exemplo:

    Sub ExampleShellForWin
        Shell("c:\windows\calc.exe",2)
    End Sub