WMI Fun !! 〜 WMIに興味がある方・システム管理者必見!! 〜
 WMI Step|WMI Sample|WMI Reference|WMI Library|My Let'snote|Personal|Link|About WMI Fun !!

WMI Fun !! > WMI Library > Win32_PrinterDriver クラス

Panasonic Let'snoteを長年愛用しています、その理由はMy Let'snoteで…
インクを買うよりもしかしたら安い?インクジェット複合機HP Photosmart 5510
白いご飯や日本酒にもとても合うにしんのきりこみがマイブームです

Win32_PrinterDriver クラス - WMI Library

Win32_PrinterDriver クラスの説明

CIM_Service は、Device および (または) SoftwareFeature によって提供される機能の表現と管理に必要な情報を含んでいる論理要素です。サービスは機能の実装を構成および管理するための汎用オブジェクトです。機能自体ではありません。
WMI Providerは、CIMWin32です。
UUIDは、522E1798-D74F-4516-94F5-C121B0F4A8CBです。


プロパティ リスト

Caption

Data Type: string
Access Type: Read Only

Caption プロパティは、オブジェクトを短いテキスト (1 行の文字列) で表した説明です。



ConfigFile

Data Type: string
Access Type: Read Only

The ConfigFile property contains the configuration file for this printer driver, (example: pscrptui.dll).



CreationClassName

Data Type: string
Access Type: Read Only

CreationClassName は、インスタンスの作成で使用されるクラス名、またはサブクラス名を示します。このクラスの他のキー プロパティと一緒に使用すると、このクラスおよびそのサブクラスのインスタンスすべてがこのプロパティによって一意に識別されます。



DataFile

Data Type: string
Access Type: Read Only

The DataFile property contains the data file for this printer driver, (example: qms810.ppd).



DefaultDataType

Data Type: string
Access Type: Read Only

The DefaultDataType property indicates the default data type for this printer driver, (example: EMF).



DependentFiles

Data Type: string
Access Type: Read Only

The DependentFiles property contains a list of dependent files for this printer driver.



Description

Data Type: string
Access Type: Read Only

Description プロパティは、オブジェクトの説明を提供します。



DriverPath

Data Type: string
Access Type: Read Only

The DriverPath property contains the path for this printer driver, (example: C:\drivers\pscript.dll).



FilePath

Data Type: string
Access Type: Read Write

The FilePath property contains the path to the INF file being used, (Example: c:\temp\driver).



HelpFile

Data Type: string
Access Type: Read Only

The HelpFile property contains the help file for this printer driver, (example: pscrptui.hlp).



InfName

Data Type: string
Access Type: Read Write

The InfName property contains the name of the INF file being used. The default is 'ntprint.INF'. This will only be different if the drivers are provided directly by the manufacturer of the printer and not the operating system.



InstallDate

Data Type: datetime
Access Type: Read Only

InstallDate プロパティは、オブジェクトがいつインストールされたかを示す datetime 値です。値がなくても、オブジェクトがインストールされていないことを示すわけではありません。



MonitorName

Data Type: string
Access Type: Read Only

The MonitorName property contains the name of the of the monitor for this printer driver, (example: PJL monitor).



Name

Data Type: string
Access Type: Read Only

The Name property indicates the driver name for this printer. This is a compound key composed of the Name, Version and SupportedPlatform values.



OEMUrl

Data Type: string
Access Type: Read Only

The OEMUrl property provides a world wide web link to the printer manufacturer's web site. Note that this property is not populated when the Win32.INF file is used and is only applicable for drivers provided directly from the manufacturer.



Started

Data Type: boolean
Access Type: Read Only

Started はサービスが開始したか (TRUE)、または停止したか (FALSE) を示すブール値です。



StartMode

Data Type: string
Access Type: Read Only

StartMode は、サービスがシステムやオペレーティング システムなどによって自動的に開始するのか、または要求に応じて開始するだけなのかを示す文字列の値です。



Status

Data Type: string
Access Type: Read Only

Status プロパティはオブジェクトの現在の状態を示す文字列です。操作可能な状態および操作不可能な状態が定義されます。操作可能な状態は、"OK"、"低下" および "障害が発生する可能性あり" です。"障害が発生する可能性あり" は、要素は適切に機能するけれども近いうちに障害が発生する可能性があることを示します。例: SMART 対応ハード ディスク。操作不可能な状態も指定できます。これは、"エラー"、"開始中"、"停止動作中" および "サービス" です。最後の "サービス" には、ディスクがミラーされている間、ユーザーのアクセス許可の一覧を再度読み込む間、または他の管理用作業が行われている間などが該当します。この作業がすべてオンラインで行われるとは限りませんが、[管理要素] は "OK" でも他の状態でもありません。



SupportedPlatform

Data Type: string
Access Type: Read Write

The SupportedPlatform property indicates the operating environments that the driver is intended for. Examples are 'Windows NT x86' or 'Windows IA64'.



SystemCreationClassName

Data Type: string
Access Type: Read Only

スコーピング システムの CreationClassName です。



SystemName

Data Type: string
Access Type: Read Only

このサービスのホストになるシステム名です



Version

Data Type: uint16
Access Type: Read Write

The Version property indicates the operating system version that the driver is intended for.




メソッド リスト

StartService

StartService メソッドは、サービスを開始状態にします。このメソッドはサービスが正常に開始すると整数 0 を返し、要求がサポートされていない場合は 1 を返し、エラーが発生した場合はその他の数値を返します。サブクラスでは、メソッドに ValueMap 修飾子を使用して可能なリターン コードのセットを指定できる場合があります。また、サブクラスでは、ValueMap の内容を '翻訳' した文字列を Values 配列修飾子として指定できる場合があります。


StopService

StopService メソッドは、サービスを停止状態にします。このメソッドはサービスが正常に停止すると整数 0 を返し、要求がサポートされていない場合は 1 を返し、エラーが発生した場合はその他の数値を返します。


AddPrinterDriver

The AddPrinterDriver method installs a printer driver. The method can return the following values:
0 - Success.
5 - Access denied.
1797 - The printer driver is unknown.
Other - For integer values other than those listed above, refer to the documentation on the Win32 error codes.



WQL サンプル

SELECT * FROM Win32_PrinterDriver

VB6/VBS
SWbemServicesクラスのExecQueryメソッドからWQLを実行可能です。
Set PrcSet = Service.ExecQuery("SELECT * FROM Win32_PrinterDriver")

VB.Net
ObjectQueryクラスのQueryStringプロパティにWQLを設定し、ManagementObjectSearcherクラスのGetメソッドからWQLを実行可能です。
Searcher.Query.QueryString = "SELECT * FROM Win32_PrinterDriver"
PrcSrc = Searcher.Get

PowerShell
Get-WmiObjectコマンドレットのqueryオプションを指定しWQLを実行可能です。
Get-WmiObject -query "SELECT * FROM Win32_PrinterDriver"


このサイトの情報について

このコンテンツはWMIの各コンポーネントが持っているWin32_PrinterDriverクラス情報を参照・抽出しリファレンスとして作成・提供しています。
参照したWMIの名前空間はroot/CIMV2、書き出し環境はWindows Server 2008 R2になります。

WMIの使い方(VB6, VBS, VBA, VB.NET, VC#, PowerShellを対象)に関してはWMI Stepも参考にしてみてください。(WMI初心者・入門編としてもおすすめです。) 各種言語を使用したWMIを使用するたたき台としてソーステンプレートも公開しています。プログラム/スクリプト作成時に役立てば…と思っています。

今後各WMI ClassをサポートしているOSの種類を掲載する予定です。
予定OS: Windows XP/Windows Vista/Windows 7/Windows Server 2003/Windows Server 2003 R2/Windows Server 2008/Windows Server 2008 R2


ご意見・ご要望・ご感想をこちらのアンケートからお待ちしています
WMIに関して調べているけど探し物が見つからない…という方はSearch Resultから検索してみましょう!!

MCP(Microsoft Certified Professional)一応MCP(Microsoft Certified Professional)、MCA(Microsoft Certified Associate)所有してたりします…

- WMI Fun !! -
http://www.wmifun.net/
Microsoft社のテクノロジーであるWMI(Windows Management Instrumentation)の使い方を
Visual Basicを使ってのんびり公開しています
WMIはVB/VBAや.Net(VB,C#)以外でもWMICやWSH(VBS,JS)・PowerShellなどスクリプト言語からも使えますよ!
Windowsベースの社内ITシステムに関する資産管理、アセットマネジメントや監視業務の効率化、
インベントリ情報収集系システムツール開発にWMIはお勧めです

This website is created by Toh.
Copyright(C) 1997-2012 WMI Fun !!. All rights reserved.
WMI Fun !!へのリンクはご自由に…相互リンクに関するお問い合わせはアンケートページからお願いします。

∧ ページの先頭へ…