windows-nt/Source/XPSP1/NT/net/config/samples/netcfg/netcfg.htm

176 lines
6.8 KiB
HTML
Raw Permalink Normal View History

2020-09-26 03:20:57 -05:00
<html xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=windows-1252">
<meta name=ProgId content=Word.Document>
<meta name=Generator content="Microsoft Word 9">
<meta name=Originator content="Microsoft Word 9">
<link rel=File-List href="./netcfg_files/filelist.xml">
<title>Network Configuration Utility sample</title>
<style>
<!--
/* Font Definitions */
@font-face
{font-family:"MS Sans Serif";
panose-1:0 0 0 0 0 0 0 0 0 0;
mso-font-charset:0;
mso-generic-font-family:swiss;
mso-font-format:other;
mso-font-pitch:variable;
mso-font-signature:3 0 0 0 1 0;}
@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;
mso-font-charset:0;
mso-generic-font-family:swiss;
mso-font-pitch:variable;
mso-font-signature:536871559 0 0 0 415 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:"";
margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
h1
{mso-style-next:Normal;
margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
page-break-after:avoid;
mso-outline-level:1;
font-size:10.0pt;
font-family:Verdana;
mso-font-kerning:0pt;
font-weight:bold;}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;
text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
{color:blue;
text-decoration:underline;
text-underline:single;}
p
{margin-right:0in;
mso-margin-top-alt:auto;
mso-margin-bottom-alt:auto;
margin-left:0in;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
pre
{margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
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;
font-size:10.0pt;
font-family:"Courier New";
mso-fareast-font-family:"Courier New";}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;
mso-header-margin:.5in;
mso-footer-margin:.5in;
mso-paper-source:0;}
div.Section1
{page:Section1;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=blue style='tab-interval:.5in'>
<div class=Section1>
<h2><a name="_top"></a><span style='font-family:Verdana'>Network Configuration
Sample (SNETCFG)<o:p></o:p></span></h2>
<p><span style='font-size:10.0pt;font-family:Arial;color:red'>[This is
preliminary documentation and subject to change.]</span><span style='font-size:
10.0pt;font-family:Verdana'><o:p></o:p></span></p>
<h3><span style='font-family:Verdana'>SUMMARY<o:p></o:p></span></h3>
<p><span style='font-size:10.0pt;font-family:Verdana'>This sample demonstrates
use of INetCfg APIs to enumerate, install and uninstall network components.<o:p></o:p></span></p>
<p><span style='font-size:10.0pt;font-family:Verdana'>The sample compiles properly
for 64-bit, builds properly with Microsoft<66> Visual C<> 6.0, and supports Plug
and Play. <o:p></o:p></span></p>
<h3><span style='font-family:Verdana'>BUILDING THE SAMPLE<o:p></o:p></span></h3>
<p><span style='font-size:10.0pt;font-family:Verdana'>To build the sample, type
<b>build</b>. This command produces the binary Snetcfg.exe, which is the sample
network configuration utility.<o:p></o:p></span></p>
<h3><span style='font-family:Verdana'>INSTALLING THE SAMPLE<o:p></o:p></span></h3>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:Verdana'>Copy the
binary snetcfg.exe to your local drive, to a directory that is listed in the
PATH environment variable.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:Verdana'><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></span></p>
<h3><span style='font-family:Verdana'>RUNNING THE SAMPLE<o:p></o:p></span></h3>
<p><span style='font-size:10.0pt;font-family:Verdana'>Type <20>snetcfg -?<3F> at a
command-line prompt to view supported options. The <20>-v<> option enables verbose
output along with other options.<o:p></o:p></span></p>
<p><span style='font-size:10.0pt;font-family:Verdana'>Some of the supported
options are:<o:p></o:p></span></p>
<p><span style='font-size:10.0pt;font-family:Verdana'>-q: query for presence of
a component<o:p></o:p></span></p>
<p><span style='font-size:10.0pt;font-family:Verdana'>-i: install a component<o:p></o:p></span></p>
<p><span style='font-size:10.0pt;font-family:Verdana'>-u: uninstall a component<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:Verdana'>To
install the Passthru driver, type <b>snetcfg -l d:\sample\netsf.inf -c s -i
ms_passthru</b>. To uninstall, type <b>snetcfg -u ms_passthru</b><o:p></o:p></span></p>
<h3><span style='font-family:Verdana'>CODE TOUR<o:p></o:p></span></h3>
<h4><span style='font-family:Verdana'>File Manifest<o:p></o:p></span></h4>
<pre><u>File<span style='mso-tab-count:2'><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> </span>Description<o:p></o:p></u></pre><pre>Idls.idl<span
style='mso-tab-count:1'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> </span>This file includes Netcfgx.idl</pre><pre>Implinc.cpp<span
style='mso-tab-count:1'><3E><><EFBFBD> </span>File including GUID definitions</pre><pre>Main.cpp<span
style='mso-tab-count:1'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> </span>File containing implementations of main and usage functions</pre><pre>Pch.h<span
style='mso-tab-count:2'><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> </span>Pre-compiled header file</pre><pre>Snetcfg.cpp<span
style='mso-tab-count:1'><3E><><EFBFBD> </span>Sample source illustrating use of INetCfg APIs</pre><pre>Snetcfg.h<span
style='mso-tab-count:1'><3E><><EFBFBD><EFBFBD><EFBFBD> </span>The header file for Snetcfg.cpp</pre><pre>Snetcfg.rc<span
style='mso-tab-count:1'><3E><><EFBFBD><EFBFBD> </span>Resource file</pre><pre><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></pre><pre><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></pre><pre><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></pre>
<p align=center style='text-align:center;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'><a
href="#_top"><span style='font-size:10.0pt;font-family:Verdana'>Top of page</span></a><span
style='font-size:10.0pt;font-family:Verdana'> <o:p></o:p></span></p>
<table border=0 cellspacing=0 cellpadding=0 width=624 style='width:6.5in;
mso-cellspacing:0in;mso-padding-alt:0in 0in 0in 0in'>
<tr style='height:1.5pt'>
<td style='background:aqua;padding:.75pt .75pt .75pt .75pt;height:1.5pt'>
<p class=MsoNormal><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
</td>
</tr>
</table>
<p style='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
style='font-size:7.5pt;font-family:"MS Sans Serif"'><3E> Microsoft Corporation
1999</span><span style='font-size:10.0pt;font-family:Verdana'> <o:p></o:p></span></p>
</div>
</body>
</html>