|
还得马蹄金,所以就不想看了,估计看得人懒得下载再看了。
粘贴已下我的,你自己对照一下了。
@echo off
rem ----------------------------------------------------------------
rem Start up PDMS, allowing for PDMSEXE being a search path, and
rem some arguments to pass into monitor
rem ----------------------------------------------------------------
setlocal
set savepath=%path%
rem ----------------------------------------------------------------
rem Set pdms_installed_dir to the folder this .bat is running in
rem This line is edited by the installer to point to your chosen folder
rem ----------------------------------------------------------------
set pdms_installed_dir=D:\AVEVA\Plant\PDMS12.0.SP6\.
rem ---------------------------------------------
rem Set evars for PDMS
rem this sets all the project variables
rem ---------------------------------------------
call "%pdms_installed_dir%\evars" "%pdms_installed_dir%"
if not "%PDMS_ACAD%"=="" goto acaddone
set acad_version=%PDMS_ACAD%
rem echo %path%
:acaddone
rem ----------------------------------------------------------------
rem The rest of this is about finding a path to
rem mon.exe within main executables directory
rem and then running it
rem ----------------------------------------------------------------
set found=
rem ----------------------------------------------------------------
rem Next two for loops set %i to the 1st token and %j to the remaining tokens
rem using space as a delimiter
rem ----------------------------------------------------------------
set remains=%PDMSEXE%
:nextSP
set nextpart=
for /F "tokens=1,* delims= " %%i in ( "%remains%" ) do set nextpart=%%i
for /F "tokens=1,* delims= " %%i in ( "%remains%" ) do set remains=%%j
if "%nextpart%" equ "" goto SPdone
call pdms_findexe "%nextpart%" mon.exe
if not "%found%"=="" goto gotMON
goto nextSP
:SPdone
rem ----------------------------------------------------------------
rem Next two for loops set %i to the 1st token and %j to the remaining tokens
rem using space as a delimiter (new at PDMS 12)
rem ----------------------------------------------------------------
set remains=%PDMSEXE%
:nextSE
set nextpart=
for /F "tokens=1,* delims=;" %%i in ( "%remains%" ) do set nextpart=%%i
for /F "tokens=1,* delims=;" %%i in ( "%remains%" ) do set remains=%%j
if "%nextpart%" equ "" goto SEdone
call pdms_findexe "%nextpart%" mon.exe
if not "%found%"=="" goto gotMON
goto nextSE
:SEdone
goto noMON
:gotMON
set monexe=%found%
rem ----------------------------------------------------------------
rem If we have no arguments, add 'graphics' so that monitor doesn't
rem think we are coming from a module-switch
rem ----------------------------------------------------------------
set args=%1 %2 %3 %4 %5 %6
if "%1"=="" set args=graphics
rem For Autocad
set PDMS_ACAD=2006
set ACAD_VERSION=%PDMS_ACAD%
set PDMS_ACAD_PATH=C:\program files\AutoCAD 2006;C:\Program Files\Common Files\Autodesk Shared
rem ----------------------------------------------------------------
rem The following directories should contain the executables - %PDMS_ACAD_PATH%
rem Alternatively, edit this macro for your own setup.
rem ----------------------------------------------------------------
set path=%PDMSEXE%\autodraftACAD;%PDMS_ACAD_PATH%;%path%
rem ----------------------------------------------------------------
rem The following directory should contain AutoCAD-style fonts used
rem by Open Design Alliance libraries on machines not equipped with
rem AutoCAD.
rem ----------------------------------------------------------------
set ACAD=%PDMSEXE%\AutoDraftFonts
rem Evar to workaround unwanted interaction of PDMS launcher and PLOT input;
set PDMS_CONSOLE_WINDOW=ACTIVE
rem -----------------------------------------------
rem We have found mon.exe somewhere, so start it up
rem with any arguments the user passed us
rem -----------------------------------------------
echo running: %monexe%\mon %args%
cmd/c "%monexe%\mon" %args%
goto end
:noMON
@echo Sorry, cannot find mon.exe within your PDMSEXE - %PDMSEXE%
pause
goto end
:end
set path=%savepath%
endlocal
|
评分
-
查看全部评分
|