How do i get the class ESRI.ArcGIS.E2API?
In ArcGIS Explorer 500 (and previous builds) this was the name of a Namespace. However if you're working with ArcGIS Explorer 900, 1200 and onwards, you will be using the newer namespace ESRI.ArcGISExplorer.Application, and you can use the static Application class to access similar things from within the Button, DockWindow or whatever add-in you have, for example:public class ButtonWalkthrough : ESRI.ArcGISExplorer.Application.Button
{
public override void OnClick()
{
MapDisplay md = ESRI.ArcGISExplorer.Application.Application.ActiveMapDisplay;
ESRI.ArcGISExplorer.Geometry.Point location = md.TrackPoint();
If you are working in ArcGIS Explorer 500 or previous, to get a reference to the E2 class which represents the running application, it's accessed from the TaskUI.E2 property, often in the CustomTaskControl constructor like this that tracks a Point on the view:public CustomTaskControl(CustomTaskUI taskUI)
{
_taskUI = taskUI;
ESRI.ArcGIS.E2API.Point location = _taskUI.E2.CurrentView.TrackPoint();