This document is archived and information here might be outdated.  Recommended version.


IEnvelope.UpperRight Property (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geometry > ESRI.ArcGIS.Geometry > Interfaces > IE > IEnvelope Interface > IEnvelope.UpperRight Property
ArcGIS Developer Help

IEnvelope.UpperRight Property

The upper right corner.

[Visual Basic .NET]
Public Property UpperRight As IPoint
[C#]
public IPoint UpperRight {get; set;}
[C++]
HRESULT get_UpperRight(
  IPoint** UpperRight
);
[C++]
HRESULT put_UpperRight(
  IPoint* UpperRight
);
[C++]
Parameters
UpperRight [out, retval]

UpperRight is a parameter of type IPoint** UpperRight
UpperRight is a parameter of type IPoint*

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

    private void printEnvelope(IEnvelope envelope)
    {
        IPoint lowerLeft = envelope.LowerLeft;
        IPoint lowerRight = envelope.LowerRight;
        IPoint upperLeft = envelope.UpperLeft;
        IPoint upperRight = envelope.UpperRight;

        String report = "LowerLeft  X  = " + lowerLeft.X + "\n" +
                        "LowerLeft  Y  = " + lowerLeft.Y + "\n\n" +
                        "LowerRight X = " + lowerRight.X + "\n" +
                        "LowerRight Y = " + lowerRight.Y + "\n\n" +
                        "UpperLeft  X  = " + upperLeft.X + "\n" +
                        "UpperLeft  Y  = " + upperLeft.Y + "\n\n" +
                        "UpperRight X = " + upperRight.X + "\n" +
                        "UpperRight Y = " + upperRight.Y;


        System.Windows.Forms.MessageBox.Show(report);
    }

Remarks


Returns or sets the UpperRight point of an Envelope .
Envelope UpperRight Example
[C#]

public void Driver()
{
   IEnvelope envelope = new EnvelopeClass();
  
   envelope.XMin = 0;
   envelope.YMin = 10;
   envelope.XMax = 20;
   envelope.YMax = 30;
  
   printEnvelope(envelope);
}
 
 private void printEnvelope(IEnvelope envelope)
 {
   IPoint lowerLeft = envelope.LowerLeft;
   IPoint lowerRight = envelope.LowerRight;
   IPoint upperLeft = envelope.UpperLeft;
   IPoint upperRight = envelope.UpperRight;
  
   String report = "LowerLeft  X  = " + lowerLeft.X  + "\n" +
                   "LowerLeft  Y  = " + lowerLeft.Y  + "\n\n" +
                   "LowerRight X = "+ lowerRight.X   + "\n" +
                   "LowerRight Y = " + lowerRight.Y  + "\n\n" +
                   "UpperLeft  X  = " + upperLeft.X  + "\n" +
                   "UpperLeft  Y  = " + upperLeft.Y  + "\n\n" +
                   "UpperRight X = "+ upperRight.X   + "\n" +
                   "UpperRight Y = "+ upperRight.Y;
 
 
  System.Windows.Forms.MessageBox.Show(report);
 }

See Also

IEnvelope Interface | IEnvelope.UpperLeft Property | IEnvelope.LowerLeft Property | IEnvelope.LowerRight Property | IEnvelope.Width Property | IEnvelope.Height Property