Leaked source code of windows server 2003
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.

196 lines
7.4 KiB

  1. <!doctype html public "-//W3C//DTD HTML 4.0 Draft//EN">
  2. <html xmlns:v="urn:schemas-microsoft-com:vml"
  3. xmlns:o="urn:schemas-microsoft-com:office:office"
  4. xmlns:w="urn:schemas-microsoft-com:office:word"
  5. xmlns="http://www.w3.org/TR/REC-html40">
  6. <head>
  7. <meta http-equiv=Content-Type content="text/html; charset=windows-1251">
  8. <meta name=ProgId content=Word.Document>
  9. <meta name=Generator content="Microsoft Word 9">
  10. <meta name=Originator content="Microsoft Word 9">
  11. <link rel=File-List href="./Registry_files/filelist.xml">
  12. <title>WMI SDK Sample - Registry</title>
  13. <!--[if gte mso 9]><xml>
  14. <o:DocumentProperties>
  15. <o:Author>Michael Maston</o:Author>
  16. <o:Template>Normal</o:Template>
  17. <o:LastAuthor>Michael Maston</o:LastAuthor>
  18. <o:Revision>5</o:Revision>
  19. <o:TotalTime>172</o:TotalTime>
  20. <o:Created>1999-06-11T21:06:00Z</o:Created>
  21. <o:LastSaved>1999-07-15T22:50:00Z</o:LastSaved>
  22. <o:Pages>1</o:Pages>
  23. <o:Words>145</o:Words>
  24. <o:Characters>827</o:Characters>
  25. <o:Company>Microsoft</o:Company>
  26. <o:Lines>6</o:Lines>
  27. <o:Paragraphs>1</o:Paragraphs>
  28. <o:CharactersWithSpaces>1015</o:CharactersWithSpaces>
  29. <o:Version>9.2720</o:Version>
  30. </o:DocumentProperties>
  31. </xml><![endif]-->
  32. <style>
  33. <!--
  34. /* Font Definitions */
  35. @font-face
  36. {font-family:"MS Mincho";
  37. panose-1:0 0 0 0 0 0 0 0 0 0;
  38. mso-font-alt:"MS Mincho";
  39. mso-font-charset:128;
  40. mso-generic-font-family:roman;
  41. mso-font-format:other;
  42. mso-font-pitch:fixed;
  43. mso-font-signature:1 134676480 16 0 131072 0;}
  44. @font-face
  45. {font-family:Verdana;
  46. panose-1:2 11 6 4 3 5 4 4 2 4;
  47. mso-font-charset:0;
  48. mso-generic-font-family:swiss;
  49. mso-font-pitch:variable;
  50. mso-font-signature:536871559 0 0 0 415 0;}
  51. @font-face
  52. {font-family:"\@MS Mincho";
  53. mso-font-charset:128;
  54. mso-generic-font-family:modern;
  55. mso-font-pitch:fixed;
  56. mso-font-signature:-1610612033 1757936891 16 0 131231 0;}
  57. /* Style Definitions */
  58. p.MsoNormal, li.MsoNormal, div.MsoNormal
  59. {mso-style-parent:"";
  60. margin:0in;
  61. margin-bottom:.0001pt;
  62. mso-pagination:widow-orphan;
  63. font-size:12.0pt;
  64. font-family:"Times New Roman";
  65. mso-fareast-font-family:"Times New Roman";
  66. color:black;}
  67. a:link, span.MsoHyperlink
  68. {color:blue;
  69. text-decoration:underline;
  70. text-underline:single;}
  71. a:visited, span.MsoHyperlinkFollowed
  72. {color:blue;
  73. text-decoration:underline;
  74. text-underline:single;}
  75. p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
  76. {margin:0in;
  77. margin-bottom:.0001pt;
  78. mso-pagination:widow-orphan;
  79. font-size:10.0pt;
  80. font-family:"Courier New";
  81. mso-fareast-font-family:"Times New Roman";}
  82. @page Section1
  83. {size:8.5in 11.0in;
  84. margin:1.0in 1.25in 1.0in 1.25in;
  85. mso-header-margin:.5in;
  86. mso-footer-margin:.5in;
  87. mso-paper-source:0;}
  88. div.Section1
  89. {page:Section1;}
  90. /* List Definitions */
  91. @list l0
  92. {mso-list-id:2085059825;
  93. mso-list-type:hybrid;
  94. mso-list-template-ids:-224211296 67698703 67698713 67698715 67698703 67698713 67698715 67698703 67698713 67698715;}
  95. @list l0:level2
  96. {mso-level-number-format:alpha-lower;
  97. mso-level-tab-stop:1.0in;
  98. mso-level-number-position:left;
  99. text-indent:-.25in;}
  100. ol
  101. {margin-bottom:0in;}
  102. ul
  103. {margin-bottom:0in;}
  104. -->
  105. </style>
  106. <!--[if gte mso 9]><xml>
  107. <o:shapedefaults v:ext="edit" spidmax="1027"/>
  108. </xml><![endif]--><!--[if gte mso 9]><xml>
  109. <o:shapelayout v:ext="edit">
  110. <o:idmap v:ext="edit" data="1"/>
  111. </o:shapelayout></xml><![endif]-->
  112. <meta name=MS-HAID content=VJsamples>
  113. </head>
  114. <body bgcolor=white lang=EN-US link=blue vlink=blue style='tab-interval:.5in'>
  115. <div class=Section1>
  116. <table border=0 cellpadding=0 width="100%" style='width:100.0%;mso-cellspacing:
  117. 1.5pt;mso-padding-alt:0in 0in 0in 0in'>
  118. <tr>
  119. <td width=160 style='width:120.0pt;background:#330099;padding:.75pt .75pt .75pt .75pt'>
  120. <p class=MsoNormal><span style='font-size:10.0pt;font-family:Verdana;
  121. color:white'>&nbsp;<nobr><b>Windows Management Instrumentation SDK Sample</b></span>
  122. <o:p></o:p></p>
  123. </td>
  124. </tr>
  125. </table>
  126. <p class=MsoPlainText><br>
  127. <strong><span style='font-size:13.5pt;font-family:Verdana'>Registry</span></strong><br>
  128. <br>
  129. <span style='font-family:Verdana;mso-fareast-font-family:"MS Mincho";
  130. mso-bidi-font-family:"Times New Roman"'>This sample illustrates how to retrieve
  131. registry data from WMI.<span style="mso-spacerun: yes"></span>Note that the
  132. accompanying MOF (registry.mof) must be compiled and loaded for this sample to
  133. run correctly.<span style="mso-spacerun: yes"></span>The MOF file contains
  134. class definitions of the Registry keys to be read by the sample.<o:p></o:p></span></p>
  135. <p class=MsoPlainText><span style='font-family:Verdana;mso-fareast-font-family:
  136. "MS Mincho";mso-bidi-font-family:"Times New Roman"'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></p>
  137. <p class=MsoPlainText><span style='font-size:12.0pt;mso-bidi-font-size:10.0pt;
  138. font-family:Verdana'>Compiling the Registry MOF<o:p></o:p></span></p>
  139. <p class=MsoPlainText>&nbsp;</p>
  140. <p class=MsoPlainText><span style='font-family:Verdana'>The Registry MOF can be
  141. compiled by doing the following:<o:p></o:p></span></p>
  142. <p class=MsoPlainText><span style='font-family:Verdana'>&nbsp;<o:p></o:p></span></p>
  143. <p class=MsoPlainText style='margin-left:.5in;text-indent:-.25in;mso-list:l0 level1 lfo2;
  144. tab-stops:list .5in'><![if !supportLists]><span style='font-family:Verdana'>1.<span
  145. style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span><![endif]><span
  146. style='font-family:Verdana'>At the command prompt, change directory to the
  147. installation drive and directory of the Registry sample (e.g., D:\&gt;Program
  148. Files\WMI\samples\Scripting\WSH\VBScript\Registry):<o:p></o:p></span></p>
  149. <p class=MsoPlainText style='margin-left:.5in'><span style='font-family:Verdana'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></p>
  150. <p class=MsoPlainText style='margin-left:.5in'><b><span style='font-family:
  151. Verdana'>CD �\Program Files\WMI\samples\Scripting\WSH\VBScript\Registry�<o:p></o:p></span></b></p>
  152. <p class=MsoPlainText style='margin-left:.5in'><b><span style='font-family:
  153. Verdana'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></b></p>
  154. <p class=MsoPlainText style='margin-left:.5in;text-indent:-.25in;mso-list:l0 level1 lfo2;
  155. tab-stops:list .5in'><![if !supportLists]><span style='font-family:Verdana'>2.<span
  156. style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span><![endif]><span
  157. style='font-family:Verdana'>Once in the installation directory, compile the
  158. Registry MOF using the WMI MOF compiler, MOFCOMP:<o:p></o:p></span></p>
  159. <p class=MsoPlainText><span style='font-family:Verdana'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></p>
  160. <p class=MsoPlainText style='margin-left:.25in;text-indent:.25in'><b><span
  161. style='font-family:Verdana'>MOFCOMP registry.mof<o:p></o:p></span></b></p>
  162. <p class=MsoPlainText><span style='font-family:Verdana'>&nbsp;<o:p></o:p></span></p>
  163. <p class=MsoPlainText><span style='font-family:Verdana'>Once the MOF is
  164. compiled, the Registry script may be run and the results of the Registry query
  165. will be displayed.<o:p></o:p></span></p>
  166. <p class=MsoPlainText><span style='font-family:Verdana'>&nbsp;<o:p></o:p></span></p>
  167. <p class=MsoNormal style='tab-stops:list .5in' l0 level1 lfo2 list .5in><span
  168. style='font-family:Arial'><a href="http://www.microsoft.com/misc/CPYRIGHT.HTM"><b>
  169. 1998-1999 Microsoft Corporation. All rights reserved.</b></a></span></p>
  170. </div>
  171. </body>
  172. </html>