其他函数(Apache OpenOffice 运行时库)
From Apache OpenOffice Wiki
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Beep
Beep 函数导致系统播放一种声音,可用于警告用户执行了错误的操作。Beep 不使用任何参数:
Beep ' creates an informative tone
Shell
可以使用 Shell 函数启动外部程序。
Shell(Pathname, Windowstyle, Param)
Pathname 定义要执行的程序的路径。
Windowstyle 定义用于启动程序的窗口。
可以使用以下值:
- 0 - 程序获得焦点并在隐藏的窗口中启动。
- 1 - 程序获得焦点并在正常大小的窗口中启动。
- 2 - 程序获得焦点并在最小化窗口中启动。
- 3 - 程序获得焦点并在最大化窗口中启动。
- 4 - 程序在正常大小的窗口中启动,但没有获得焦点。
- 6 - 程序在最小化窗口中启动,焦点保留在当前窗口中。
- 10 - 程序在全屏模式下启动。
第三个参数 Param 允许将命令行参数传送到要启动的程序。
Wait
Wait 函数使程序执行终止指定的时间。等待时间是以毫秒为单位指定的。命令
Wait 2000
指定中断 2 秒(2000 毫秒)。
Environ
Environ 函数返回操作系统的环境变量。根据系统和配置情况,此处可以保存各种类型的数据。以下调用可确定操作系统临时目录的环境变量:
Dim TempDir
TempDir=Environ ("TEMP")
Content on this page is licensed under the Public Documentation License (PDL). |