Shell funkcija

Paleidžia kitą programą ir, jei reikia, apibrėžia atitinkamą lango stilių.

Sintaksė:

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

Parametrai:

Kelio vardas

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

„Windows“ stilius

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

note

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


The following values are possible:

Windowstyle

Meaning

0

Pagrindinis dėmesys skiriamas paslėptam programos langui.

Not implemented in LibreOffice.

1

Pagrindinis dėmesys skiriamas standartinio dydžio programos langui.

Not implemented in LibreOffice.

2

Didžiausias dėmesys skiriamas sumažintam programos langui.

3

didžiausias dėmesys skiriamas maksimaliam programos langui.

4

Standartinio dydžio programos langas, be fokusavimo.

Not implemented in LibreOffice.

6

Sumažintas programos langas, fokusavimas lieka aktyviame lange.

Not implemented in LibreOffice.

10

Visas ekranas.


note

Windowstyle 3 and 10 are equivalent in Windows systems.


Pram

String that specifies additional arguments passed to the program.

bSync

Jei ši reikšmė yra true, komanda Shell ir visos „LibreOffice“ užduotys laukia, kol baigsis apvalkalo procesas. Jei reikšmė yra false, apvalkalas baigia darbą iš karto. Numatytoji reikšmė yra false.

Klaidos kodai:

5 Neteisingas procedūros iškvietimas

53 failas nerastas

73 Nėra realizuota

Pavyzdys:


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

Paremkite mus!