Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

231 lines
9.6 KiB

  1. <html xmlns:v="urn:schemas-microsoft-com:vml"
  2. xmlns:o="urn:schemas-microsoft-com:office:office"
  3. xmlns:w="urn:schemas-microsoft-com:office:word"
  4. xmlns="http://www.w3.org/TR/REC-html40">
  5. <head>
  6. <meta http-equiv=Content-Type content="text/html; charset=windows-1252">
  7. <meta name=ProgId content=Word.Document>
  8. <meta name=Generator content="Microsoft Word 9">
  9. <meta name=Originator content="Microsoft Word 9">
  10. <link rel=File-List href="./readme_files/filelist.xml">
  11. <title>TestWMI</title>
  12. <style>
  13. <!--
  14. /* Font Definitions */
  15. @font-face
  16. {font-family:Courier;
  17. panose-1:0 0 0 0 0 0 0 0 0 0;
  18. mso-font-alt:"Courier New";
  19. mso-font-charset:0;
  20. mso-generic-font-family:modern;
  21. mso-font-format:other;
  22. mso-font-pitch:fixed;
  23. mso-font-signature:3 0 0 0 1 0;}
  24. @font-face
  25. {font-family:"MS Sans Serif";
  26. panose-1:0 0 0 0 0 0 0 0 0 0;
  27. mso-font-charset:0;
  28. mso-generic-font-family:swiss;
  29. mso-font-format:other;
  30. mso-font-pitch:variable;
  31. mso-font-signature:3 0 0 0 1 0;}
  32. @font-face
  33. {font-family:Verdana;
  34. panose-1:2 11 6 4 3 5 4 4 2 4;
  35. mso-font-charset:0;
  36. mso-generic-font-family:swiss;
  37. mso-font-pitch:variable;
  38. mso-font-signature:536871559 0 0 0 415 0;}
  39. /* Style Definitions */
  40. p.MsoNormal, li.MsoNormal, div.MsoNormal
  41. {mso-style-parent:"";
  42. margin:0in;
  43. margin-bottom:.0001pt;
  44. mso-pagination:widow-orphan;
  45. font-size:12.0pt;
  46. font-family:"Times New Roman";
  47. mso-fareast-font-family:"Times New Roman";
  48. color:black;}
  49. h2
  50. {margin-right:0in;
  51. mso-margin-top-alt:auto;
  52. mso-margin-bottom-alt:auto;
  53. margin-left:0in;
  54. mso-pagination:widow-orphan;
  55. mso-outline-level:2;
  56. font-size:18.0pt;
  57. font-family:"Times New Roman";
  58. color:black;
  59. font-weight:bold;}
  60. h3
  61. {margin-right:0in;
  62. mso-margin-top-alt:auto;
  63. mso-margin-bottom-alt:auto;
  64. margin-left:0in;
  65. mso-pagination:widow-orphan;
  66. mso-outline-level:3;
  67. font-size:13.5pt;
  68. font-family:"Times New Roman";
  69. color:black;
  70. font-weight:bold;}
  71. h4
  72. {margin-right:0in;
  73. mso-margin-top-alt:auto;
  74. mso-margin-bottom-alt:auto;
  75. margin-left:0in;
  76. mso-pagination:widow-orphan;
  77. mso-outline-level:4;
  78. font-size:12.0pt;
  79. font-family:"Times New Roman";
  80. color:black;
  81. font-weight:bold;}
  82. a:link, span.MsoHyperlink
  83. {color:blue;
  84. text-decoration:underline;
  85. text-underline:single;}
  86. a:visited, span.MsoHyperlinkFollowed
  87. {color:purple;
  88. text-decoration:underline;
  89. text-underline:single;}
  90. p
  91. {margin-right:0in;
  92. mso-margin-top-alt:auto;
  93. mso-margin-bottom-alt:auto;
  94. margin-left:0in;
  95. mso-pagination:widow-orphan;
  96. font-size:12.0pt;
  97. font-family:"Times New Roman";
  98. mso-fareast-font-family:"Times New Roman";
  99. color:black;}
  100. pre
  101. {margin:0in;
  102. margin-bottom:.0001pt;
  103. mso-pagination:widow-orphan;
  104. tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt;
  105. font-size:10.0pt;
  106. font-family:"Courier New";
  107. mso-fareast-font-family:"Courier New";
  108. color:black;}
  109. @page Section1
  110. {size:8.5in 11.0in;
  111. margin:1.0in 1.25in 1.0in 1.25in;
  112. mso-header-margin:.5in;
  113. mso-footer-margin:.5in;
  114. mso-paper-source:0;}
  115. div.Section1
  116. {page:Section1;}
  117. -->
  118. </style>
  119. <!--[if gte mso 9]><xml>
  120. <o:shapedefaults v:ext="edit" spidmax="1027"/>
  121. </xml><![endif]--><!--[if gte mso 9]><xml>
  122. <o:shapelayout v:ext="edit">
  123. <o:idmap v:ext="edit" data="1"/>
  124. </o:shapelayout></xml><![endif]-->
  125. <meta name=Template content="C:\PROGRAM FILES\MICROSOFT OFFICE\OFFICE\html.dot">
  126. </head>
  127. <body bgcolor=white lang=EN-US link=blue vlink=purple style='tab-interval:.5in'
  128. leftmargin=8>
  129. <div class=Section1>
  130. <h2><span style='font-family:Verdana'>testwmi � WMI Test Application<o:p></o:p></span></h2>
  131. <h3><span style='font-family:Verdana'>SUMMARY<o:p></o:p></span></h3>
  132. <p><span style='font-size:10.0pt;font-family:Verdana'>testwmi is a Win32
  133. application that allows one to query and set properties of WMI GUIDs exported
  134. by the E100BEX sample. ExampleSetUINT_OID, a property of E100BExampleSetUINT_OID,
  135. is the only one that can be set. If you want to use this application to test
  136. custom GUIDs exported by your driver then, simply add the class names of the
  137. GUIDs to the following array and recompile the program. The array is defined at
  138. the beginning in testwmi.cpp file as follows.<o:p></o:p></span></p>
  139. <p><span style='font-size:10.0pt;font-family:Verdana'>LpszClasses<o:p></o:p></span></p>
  140. <p><span style='font-size:10.0pt;font-family:Verdana'>By default, the
  141. application connects to root\wmi namespace. You can redefine the macro
  142. DEFAULT_NAMESPACE that is defined in testwmi.h header file to connect to a
  143. different namespace.<o:p></o:p></span></p>
  144. <p class=MsoNormal><span style='font-size:10.0pt;font-family:Verdana'>The code
  145. is 64-bit compliant. The application is for Windows 2000 or higher and Window
  146. 98SE or higher operating systems. <o:p></o:p></span></p>
  147. <h3><span style='font-family:Verdana'>BUILDING THE SAMPLE<o:p></o:p></span></h3>
  148. <p><span style='font-size:10.0pt;font-family:Verdana'>The sample builds
  149. properly with Microsoft� Visual C� 6.0 using the build utility in Windows 2000
  150. or higher DDK build environment. Run the <b>build</b> command from this directory
  151. to build the sample. This creates a binary testwmi.exe. If you are building the
  152. sample for Windows 98SE or higher operating systems then, make sure to comment
  153. out the following line in the Sources file to build an ANSI version.<o:p></o:p></span></p>
  154. <p><span style='font-size:10.0pt;font-family:"Courier New";color:windowtext'>C_DEFINES=
  155. $(C_DEFINES) -DUNICODE -D_UNICODE</span><span style='font-size:10.0pt;
  156. font-family:Verdana'><o:p></o:p></span></p>
  157. <h3><span style='font-family:Verdana'>USING THE SAMPLE<o:p></o:p></span></h3>
  158. <p><span style='font-size:10.0pt;mso-bidi-font-size:12.0pt;font-family:Verdana'>When
  159. you run the program, it may take up to 10 seconds before the main dialog box
  160. appears. In the main dialog box, when you select a class from the combo list
  161. box, its instances, if any, are listed in the left pane. By default, the first
  162. instance is selected and its properties are listed in the right pane. As you
  163. select another instance, the right pane is updated with the properties of the
  164. selected instance. You can view/modify a property by double-clicking on the
  165. property name. You can only modify a scalar property of string or numeric type
  166. using this sample.<o:p></o:p></span></p>
  167. <h3><span style='font-family:Verdana'>CODE TOUR<o:p></o:p></span></h3>
  168. <h4><span style='font-family:Verdana'>File Manifest<o:p></o:p></span></h4>
  169. <pre><u><! ---------------- Snip Snip ---------------- >Files<span style="mso-spacerun: yes">�������� </span>Description<o:p></o:p></u></pre><pre>readme.htm<span style="mso-spacerun: yes">��� </span>The documentation for this sample (this file)</pre><pre><span
  170. style='font-family:Courier'>Sources<span style="mso-spacerun: yes">������ </span>The generic file for building the code sample<o:p></o:p></span></pre><pre><span
  171. style='font-family:Courier'>testwmi.rc<span style="mso-spacerun: yes">��� </span>The resource file for the code sample<o:p></o:p></span></pre><pre><span
  172. style='font-family:Courier'>testwmi.h<span style="mso-spacerun: yes">���� </span>Header file containing data structures, defines and function prototypes.<o:p></o:p></span></pre><pre><span
  173. style='font-family:Courier'>testwmi.cpp<span style="mso-spacerun: yes">�� </span>File containing winmain, dialog procedures and other non-wmi functions.<o:p></o:p></span></pre><pre><span
  174. style='font-family:Courier'>Wmicode.cpp<span style="mso-spacerun: yes">�� </span>File containing code for wmi operation.<o:p></o:p></span></pre>
  175. <p style='margin:0in;margin-bottom:.0001pt;tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><span
  176. style='font-size:10.0pt;font-family:Courier;mso-fareast-font-family:"Courier New";
  177. mso-bidi-font-family:"Courier New"'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></p>
  178. <p style='margin:0in;margin-bottom:.0001pt;tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><span
  179. style='font-size:10.0pt;font-family:Courier;mso-fareast-font-family:"Courier New";
  180. mso-bidi-font-family:"Courier New"'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></p>
  181. <p align=center style='margin:0in;margin-bottom:.0001pt;text-align:center;
  182. tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><span
  183. style='font-size:10.0pt;font-family:"Courier New";mso-fareast-font-family:"Courier New"'><a
  184. href="#top"><span style='font-family:Verdana'>Top of page</span></a></span><span
  185. style='font-size:10.0pt;font-family:Verdana;mso-fareast-font-family:"Courier New";
  186. mso-bidi-font-family:"Courier New"'> <o:p></o:p></span></p>
  187. <pre><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></pre>
  188. <table border=0 cellspacing=0 cellpadding=0 width=624 style='width:6.5in;
  189. mso-cellspacing:0in;mso-padding-alt:0in 0in 0in 0in'>
  190. <tr style='height:1.5pt'>
  191. <td style='background:aqua;padding:.75pt .75pt .75pt .75pt;height:1.5pt'>
  192. <p class=MsoNormal><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
  193. </td>
  194. </tr>
  195. </table>
  196. <pre><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></pre><pre><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></pre>
  197. <p style='margin:0in;margin-bottom:.0001pt;tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><span
  198. style='font-size:7.5pt;font-family:"MS Sans Serif";mso-fareast-font-family:
  199. "Courier New";mso-bidi-font-family:"Courier New"'>� 1999 Microsoft Corporation</span><span
  200. style='font-size:10.0pt;font-family:Verdana;mso-fareast-font-family:"Courier New";
  201. mso-bidi-font-family:"Courier New"'> <o:p></o:p></span></p>
  202. </div>
  203. </body>
  204. </html>