C# 클래스 MapAndPageLayoutSynchApp.ControlsSynchronizer

This class is used to synchronize a given PageLayoutControl and a MapControl. When initialized, the user must pass the reference of these control to the class, bind the control together by calling 'BindControls' which in turn sets a joined Map referenced by both control; and set all the buddy controls joined between these two controls. When alternating between the MapControl and PageLayoutControl, you should activate the visible control and deactivate the other by calling ActivateXXX. This class is limited to a situation where the controls are not simultaneously visible.
파일 보기 프로젝트 열기: Esri/arcobjects-sdk-community-samples 1 사용 예제들

공개 메소드들

메소드 설명
ActivateMap ( ) : void

Activate the MapControl and deactivate the PagleLayoutControl

ActivatePageLayout ( ) : void

Activate the PagleLayoutControl and deactivate the MapCotrol

AddFrameworkControl ( object control ) : void

by passing the application's toolbars and TOC to the synchronization class, it saves you the management of the buddy control each time the active control changes. This method ads the framework control to an array; once the active control changes, the class iterates through the array and calls SetBuddyControl on each of the stored framework control.

BindControls ( IMapControl3 mapControl, IPageLayoutControl2 pageLayoutControl, bool activateMapFirst ) : void

bind the MapControl and PageLayoutControl together by assigning a new joint focus map

BindControls ( bool activateMapFirst ) : void

bind the MapControl and PageLayoutControl together by assigning a new joint focus map

ControlsSynchronizer ( ) : System

default constructor

ControlsSynchronizer ( IMapControl3 mapControl, IPageLayoutControl2 pageLayoutControl ) : System

class constructor

RemoveFrameworkControl ( object control ) : void

Remove a framework control from the managed list of controls

RemoveFrameworkControlAt ( int index ) : void

Remove a framework control from the managed list of controls by specifying its index in the list

ReplaceMap ( IMap newMap ) : void

given a new map, replaces the PageLayoutControl and the MapControl's focus map

비공개 메소드들

메소드 설명
SetBuddies ( object buddy ) : void

when the active control changes, the class iterates through the array of the framework controls and calls SetBuddyControl on each of the controls.

메소드 상세

ActivateMap() 공개 메소드

Activate the MapControl and deactivate the PagleLayoutControl
public ActivateMap ( ) : void
리턴 void

ActivatePageLayout() 공개 메소드

Activate the PagleLayoutControl and deactivate the MapCotrol
public ActivatePageLayout ( ) : void
리턴 void

AddFrameworkControl() 공개 메소드

by passing the application's toolbars and TOC to the synchronization class, it saves you the management of the buddy control each time the active control changes. This method ads the framework control to an array; once the active control changes, the class iterates through the array and calls SetBuddyControl on each of the stored framework control.
public AddFrameworkControl ( object control ) : void
control object
리턴 void

BindControls() 공개 메소드

bind the MapControl and PageLayoutControl together by assigning a new joint focus map
public BindControls ( IMapControl3 mapControl, IPageLayoutControl2 pageLayoutControl, bool activateMapFirst ) : void
mapControl IMapControl3
pageLayoutControl IPageLayoutControl2
activateMapFirst bool true if the MapControl supposed to be activated first
리턴 void

BindControls() 공개 메소드

bind the MapControl and PageLayoutControl together by assigning a new joint focus map
public BindControls ( bool activateMapFirst ) : void
activateMapFirst bool true if the MapControl supposed to be activated first
리턴 void

ControlsSynchronizer() 공개 메소드

default constructor
public ControlsSynchronizer ( ) : System
리턴 System

ControlsSynchronizer() 공개 메소드

class constructor
public ControlsSynchronizer ( IMapControl3 mapControl, IPageLayoutControl2 pageLayoutControl ) : System
mapControl IMapControl3
pageLayoutControl IPageLayoutControl2
리턴 System

RemoveFrameworkControl() 공개 메소드

Remove a framework control from the managed list of controls
public RemoveFrameworkControl ( object control ) : void
control object
리턴 void

RemoveFrameworkControlAt() 공개 메소드

Remove a framework control from the managed list of controls by specifying its index in the list
public RemoveFrameworkControlAt ( int index ) : void
index int
리턴 void

ReplaceMap() 공개 메소드

given a new map, replaces the PageLayoutControl and the MapControl's focus map
public ReplaceMap ( IMap newMap ) : void
newMap IMap
리턴 void