亚洲av色香蕉一区二区三区,十四以下岁毛片带血a级,亚洲 校园 欧美 国产 另类,亚洲av日韩av一区谷露,色欲av无码一区二区三区

  • 相關(guān)軟件
    >Gettype 創(chuàng)建者:webmaster 更新時(shí)間:2005-10-14 00:09

    將系統(tǒng)環(huán)境變量 %ERRORLEVEL% 設(shè)置為與指定的 Windows 操作系統(tǒng)相關(guān)的值。


    語法


    gettype [/s Computer [/u [Domain\]User [/p [Password]]]] {/role | /sp | /ver | /minv | /majv | /type | /build}


    參數(shù)



    /s Computer
    指定遠(yuǎn)程計(jì)算機(jī)名稱或 IP 地址(不能使用反斜杠)。默認(rèn)值是本地計(jì)算機(jī)。此參數(shù)適用于在命令中指定的所有文件和文件夾。
    /u [Domain\]User
    使用特定用戶帳戶的權(quán)限運(yùn)行腳本。該默認(rèn)值是系統(tǒng)權(quán)限。
    /p [Password]
    指出 /u 參數(shù)中指定的用戶帳戶的密碼。
    /role
    返回操作系統(tǒng)的角色。
    /sp
    返回已安裝的最新 service pack。
    /ver
    返回版本信息。
    /minv
    只返回次版本。
    /majv
    只返回主版本。
    /type
    返回所安裝操作系統(tǒng)的類型。
    /build
    返回所安裝操作系統(tǒng)的內(nèi)部版本號(hào)碼。
    /?
    在命令提示符下顯示幫助。


    注釋



    • 在批處理文件中執(zhí)行某些操作之前,管理員可以使用 gettype 檢測混合環(huán)境中 Windows 軟件的安裝信息。有時(shí),只在運(yùn)行特定的 Windows 操作系統(tǒng)的客戶端計(jì)算機(jī)或服務(wù)器上運(yùn)行軟件或腳本是非常必要的。
    • Gettype 可識(shí)別下列操作系統(tǒng):
         

           
      • Windows XP Home Editionid=personal>
           
      • Windows XP Professionalid=pro>
           
      • Windows Server 2003 Standard Editionid=Server>
           
      • Windows Server 2003 Enterprise Editionid=AdvServer>
           
      • Windows Server 2003 Datacenter Editionid=Datacenter>
           
      • Windows Server 2003 Web Editionid=WebServer>

      •    

    • 與大多數(shù)命令行工具不同,gettype 成功執(zhí)行后不返回 0。而是返回表明當(dāng)前操作系統(tǒng)產(chǎn)品類型的代碼。
         

      Gettype 查詢href="HELP=glossary.hlp TOPIC=gls_registry">注冊(cè)表中的安裝類型并將錯(cuò)誤值設(shè)置為下表中描述的值,以此來確定操作系統(tǒng)類型。


         
         
           
             
             
           
           
             
             
           
           
             
             
           
           
             
             
           
           
             
             
           
           
             
             
           
           
             
             
           
         
       
      ERRORLEVEL描述
      1Windows XP Home Editionid=personal>
      2Windows XP Professionalid=pro>
      3Windows Server 2003 Standard Editionid=Server>
      4Windows Server 2003 Enterprise Editionid=AdvServer>
      5Windows Server 2003 Datacenter Editionid=Datacenter>
      6Windows Server 2003 Web Editionid=WebServer>

         

      Gettype 查詢href="HELP=glossary.hlp TOPIC=gls_registry">注冊(cè)表中的安裝類型并將錯(cuò)誤值設(shè)置為下表中描述的值,以此來確定操作系統(tǒng)角色。


         
         
           
             
             
           
           
             
             
           
           
             
             
           
           
             
             
           
         
       
      ERRORLEVEL描述
      1域控制器
      2成員服務(wù)器
      3工作組

    • 發(fā)生錯(cuò)誤事件時(shí),gettype 返回 errorlevel 值 255。
    • 如果沒有安裝 service pack,則 ERRORLEVEL 為 0。如果安裝了 service pack 1,則 ERRORLEVEL 為 1。如果安裝了 service pack 2,則 ERRORLEVEL 為 2,依此類推。
    • 如果安裝了 Windows XPid=windowsxp>,則主版本為 5 且將 ERRORLEVEL 解釋為 5000。如果次版本為 1,則將 ERRORLEVEL 解釋為 100。若要同時(shí)獲取主版本和次版本,則將 ERRORLEVEL 解釋為 5100。如果發(fā)生某個(gè)錯(cuò)誤條件,則將 ERRORLEVEL 設(shè)置為 255。


    示例


    通過在批處理文件中使用 gettype,可以創(chuàng)建只在檢測到特定的平臺(tái)時(shí)才運(yùn)行的腳本。例如,如果您正在運(yùn)行 Windows NT,則下列批處理文件檢測操作系統(tǒng)類型。如果您未運(yùn)行 Windows NT,則它將退出腳本。



    @echo off
    REM 批處理文件以檢測操作系統(tǒng)
    REM ----------------------------------
    if Windows_NT == %OS% goto WINNT
    echo You are NOT running Windows NT (Windows 95/98 perhaps?)
    goto END

    :WINNT
    gettype.exe

    if errorlevel=255 goto FILENOTFOUND

    echo You are running Windows NT.
    echo More Specifically:
    echo

    if ERRORLEVEL=5 goto FIVE
    if ERRORLEVEL=4 goto FOUR
    if ERRORLEVEL=3 goto THREE
    if ERRORLEVEL=2 goto TWO
    if ERRORLEVEL=1 goto ONE

    :FILENOTFOUND
    echo
    echo Gettype not found.
    echo
    goto END

    :FIVE
    echo Windows Server 2003 Datacenter Edition.
    goto END

    :FOUR
    echo Windows Server 2003 Enterprise Edition.
    goto END

    :THREE
    echo Windows Server 2003 Standard Edition.
    goto END

    :TWO
    echo Windows XP Professional.
    goto END

    :ONE
    echo Windows XP Home Edition.
    goto END

    :END
    pause


    格式化圖例




     
       
       
     
     
       
       
     
     
       
       
     
     
       
       
     
     
       
       
     
     
       
       
     
     
       
       
     

    格式含義
    斜體用戶必須提供的信息
    粗體用戶必須準(zhǔn)確鍵入的要顯示的元素
    省略號(hào) (...)在命令行中可多次重復(fù)的參數(shù)
    中括號(hào) ([])可選項(xiàng)
    大括號(hào) ({});選項(xiàng)用豎線 (|) 分隔。例如:{even|odd}用戶必須從選項(xiàng)集合中選擇一個(gè)
    Courier 字體代碼或程序輸出
    相關(guān)文章
    本頁查看次數(shù):