IMapDocument.ReplaceContents(IMxdContents pObject)

本文介绍如何使用ReplaceContents方法来替换MXD文档的内容。该方法允许用指定的地图、页面布局、地图控件或页面布局控件的内容来替换当前文档的内容。在调用此方法前,需创建新的或打开现有的MXD文档。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Replaces the contents of the MapDocument with the contents of the specified Map, PageLayout, MapControl or PageLayoutControl. Before using the ReplaceContents method a New MapDocument must be created or an existing MapDocument must be Open.

If a MapControl  is passed to the ReplaceContents method the MapDocument will be replaced with the IMapControl2::Map. Likewise, if a PageLayoutControl is passed to the ReplaceContents method the MapDocument will be replaced with the IPageLayoutControl::PageLayout.

If the MapDocument contents is replaced with the contents of a Map or MapControl a portriat PageLayout containing the map will be created.

 在使用这个方法之前,或者建立一个新文档或者打开一个已经存在的新文档.

如果MapControl传给方法,MXD文档将要被IMapControl2::Map代替.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值