📄 edn_ esri developer network.mht
字号:
=09
=09
<a href=3D"index.cfm" target=3D"_top"><img =
src=3D"cid:003901c77435$1741cb28$_CDOSYS2.0" height=3D"33" width=3D"301" =
alt=3D"EDN (ESRI Developer Network)" title=3D"EDN (ESRI Developer =
Network)" /></a>
<h1>EDN: ESRI Developer Network</h1>
</div>
=09
=09
=09
=09
=09
=09
<div id=3D"wrap">
<div id=3D"loginStatus">
=09
<a =
href=3D"index.cfm?fa=3Dlogin.loginUser&pagewanted=3Dfa%3DcodeExch%2Es=
ampleDetail%26pg%3D%2Farcobjects%2F9%2E1%2FSamples%2FControls%2FPageLayou=
tControl%2FLoadMapDocument%2FLoadMapDocument%2Ehtm" =
target=3D"_top">Login</a>
=09
</div>
<a href=3D"http://edn.esri.com/" target=3D"_top"><img =
src=3D"cid:003a01c77435$1741cb28$_CDOSYS2.0" alt=3D"EDN (ESRI Developer =
Network)" title=3D"EDN (ESRI Developer Network)" /></a>
</div>
=09
<div id=3D"mainNav">
<a href=3D"index.cfm?fa=3Dhome.welcome" target=3D"_top">home</a>
<a href=3D"index.cfm?fa=3DdocLibrary.gateway" =
target=3D"_top">documentation library</a>
<a href=3D"index.cfm?fa=3Dforums.gateway" target=3D"_top">discussion =
forums</a>
<a href=3D"index.cfm?fa=3Ddownloads.gateway" =
target=3D"_top">downloads</a>
<a class=3D"selected" href=3D"index.cfm?fa=3DcodeExch.gateway" =
target=3D"_top">code exchange</a>
<a href=3D"index.cfm?fa=3Dmedia.gateway" target=3D"_top">media =
center</a>
=09
=09
<a href=3D"index.cfm?fa=3Dconferences.gateway" =
target=3D"_top">Conferences</a>
=09
</div>
=09
<div id=3D"uberNav">
<a href=3D"http://www.esri.com" target=3D"_top">ESRI.com</a> |
<a href=3D"http://support.esri.com" target=3D"_top">Support</a> |
<a href=3D"http://support.esri.com/index.cfm?fa=3DsiteMap.siteguide" =
target=3D"_top">More ESRI Sites...</a>
</div>
=09
</div>
<div id=3D"gatewayBanner"><h2>EDN Code Exchange</h2></div>
=09
=09
<div id=3D"updated">
Updated=20
Mar 31, 2007=20
</div>
<table id=3D"hybridLayout" summary=3D"layout table">
<tr>
<td id=3D"mainContent">=20
<style type=3D"text/css">
code#c {color: green;} /* used for comments */
code#k {color: blue;} /* used for keywords */
hr {color: black; height: 100%;} /* used for separating procedures */
</style>
<div id=3D"ednDocContent">
<div id=3D"nsbanner">
<div id=3D"bannerrow1">
<table class=3D"bannerparthead" CELLSPACING=3D"0" =
CELLPADDING=3D"5" frame=3D"void" border=3D"0">
<tr id=3D"hdr">
<td class=3D"runninghead" nowrap=3D"true">Samples</td>
<td class=3D"tools">
<img src=3D"cid:003b01c77435$1741cb28$_CDOSYS2.0">
</td>
</tr>
</table>
</div>
<div id=3D"TitleRow">
<H1 class=3D"dtH1">
<a name=3D"ITesting.Filter">
</a>LoadMapDocument</H1>
</div>
</div>
<div id=3D"sampletext" valign=3D"bottom">
<B>Description:</B>
<BR>
<BR>
<!-- A Description of what your tool does-->
<TEXT>
The browse dialog allows users to search and select
map documents (*.mxd, *.mxt and *.pmf), which is loaded into the =
PageLayoutControl using the
LoadMxFile method. As .pmf map documents can be password =
protected then this is checked for using =
IMapDocument::IsPasswordProtected.
If the document is a password protected the user will be prompted for =
the password.
</TEXT>
<TABLE bgcolor=3D"#DDE0E3" class=3D"Products">
<TD>
<B>Products:</B>
<DIV style=3D"position: relative; left: 15px">
<P>
</P>Engine:
VB6,
VC++,
C#,
VB.NET</DIV>
<P>
</P>
<P>
</P>
<B>Platforms: </B>Windows<P></P><B>Minimum ArcGIS Release: =
</B>9.0</TD>
</TABLE>
<BR>
<B>How to use:</B>
<div>
<span class=3D"lang">[VB6]</span>
<OL>
<LI>Either run the LoadMapDocument.exe or open the =
LoadMapDocument.vbp and run from within the project.
(Note the Microsoft Common Dialog Control (Comdlg32.ocx) is =
used in this sample).</LI>
<LI>Browse to a map document to load into the =
PageLayoutControl. The map document can
be an ArcMap document, an ArcMap template, or a =
Published Map File.</LI>
</OL>
</div>
<div>
<span class=3D"lang">[VC++, .NET]</span>
<OL>
<LI>Build and run LoadMapControl.exe</LI>
<LI>Click on "Load Map Document" and browse your file system =
for MXD, MXT, or PMF file.</LI>
<LI>If a published map is password protected a password window =
will prompt user for the correct password.</LI>
</OL>
</div>
<div>
<span class=3D"lang">[VC++]</span>
<P>
<B>VC++ Notes</B>
</P>
<OL>
<LI>If you are using Windows NT or Windows 2000, in StdAfx.h =
file change commdlg32.ocx destination to your current System32 folder in =
Windows directory. </LI>
</OL>
</div>
<BR>
<div id=3D"tabBox">
<div id=3D"tabNav">
<a id=3D"tab1" href=3D"javascript: tabBox('1','4');">VB6</a>
<a id=3D"tab2" href=3D"javascript: tabBox('2','4');">VC++</a>
<a id=3D"tab3" href=3D"javascript: tabBox('3','4');">C#</a>
<a id=3D"tab4" href=3D"javascript: =
tabBox('4','4');">VB.NET</a>
</div>
<div id=3D"tabContent1" class=3D"contentArea">
<table summary=3D"VB" class=3D"" CELLPADDING=3D"5" =
CELLSPACING=3D"0">
<TR VALIGN=3D"TOP" BGCOLOR=3D"#DDE0E3">
<TD class=3D"filesTD">
<B>File</B>
</TD>
<TD class=3D"filesTD">
<B>Description</B>
</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapDocument.frm<DIV =
class=3D"clsCode"><a target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_Basic/frmLoadMapDocument.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">VB form file for the LoadMapDocument =
project.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">Password.frm<DIV =
class=3D"clsCode"><a target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_Basic/frmPassword.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">VB form file for the LoadMapDocument =
project.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapDocument.vbp</TD>
<TD class=3D"filesTD">VB Project file.</TD>
</TR>
</table>
</div>
<div id=3D"tabContent2" class=3D"contentArea">
<table summary=3D"VCPP" class=3D"" CELLPADDING=3D"5" =
CELLSPACING=3D"0">
<TR VALIGN=3D"TOP" BGCOLOR=3D"#DDE0E3">
<TD class=3D"filesTD">
<B>File</B>
</TD>
<TD class=3D"filesTD">
<B>Description</B>
</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMap.cpp<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/cppLoadMap.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Implementation of LoadMap =
class.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMap.h<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/hLoadMap.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Header file for LoadMap class.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapControl.cpp<DIV =
class=3D"clsCode"><a target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/cppLoadMapControl.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Implementation of LoadMapControl =
class.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapControl.dsp</TD>
<TD class=3D"filesTD">Project file for LoadMapControl =
class.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapControl.dsw</TD>
<TD class=3D"filesTD">Workspace for project file.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapControl.rc</TD>
<TD class=3D"filesTD">Resource file.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">Password.cpp<DIV =
class=3D"clsCode"><a target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/cppPassword.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Implementation of Password =
class.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">Password.h<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/hPassword.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Header file for Password class.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">resource.h<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/hresource.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Resource header file.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">StdAfx.cpp<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/cppStdAfx.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Standard implementation.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">StdAfx.h<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/Visual=
_CPP/hStdAfx.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Header file for Standard =
implementation.</TD>
</TR>
</table>
</div>
<div id=3D"tabContent3" class=3D"contentArea">
<table summary=3D"CS" class=3D"" CELLPADDING=3D"5" =
CELLSPACING=3D"0">
<TR VALIGN=3D"TOP" BGCOLOR=3D"#DDE0E3">
<TD class=3D"filesTD">
<B>File</B>
</TD>
<TD class=3D"filesTD">
<B>Description</B>
</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD"> AssemblyInfo.cs <DIV =
class=3D"clsCode"><a target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/CSharp=
/csAssemblyInfo.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Assembly information.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD"> LoadMap.cs<DIV class=3D"clsCode"><a =
target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/CSharp=
/csLoadMap.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Class File.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapControl.csproj</TD>
<TD class=3D"filesTD">Project File.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD">LoadMapControl.sln</TD>
<TD class=3D"filesTD">Solution File.</TD>
</TR>
<TR VALIGN=3D"TOP">
<TD class=3D"filesTD"> Password.cs<DIV =
class=3D"clsCode"><a target=3D"_blank" =
href=3D"http://edn.esri.com/index.cfm?fa=3DcodeExch.sampleDetail&pg=3D=
/arcobjects/9.1/Samples/Controls/PageLayoutControl/LoadMapDocument/CSharp=
/csPassword.htm">(view code)</A></DIV></TD>
<TD class=3D"filesTD">Class File.</TD>
</TR>
</table>
</div>
<div id=3D"tabContent4" class=3D"contentArea">
<table summary=3D"VBNET" class=3D"" CELLPADDING=3D"5" =
CELLSPACING=3D"0">
<TR VALIGN=3D"TOP" BGCOLOR=3D"#DDE0E3">
<TD class=3D"filesTD">
<B>File</B>
</TD>
<TD class=3D"filesTD">
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -