Bottom Property

Returns the distance in pixels between the top edge of the containing image and the bottom edge of the specified rectangle. Read-only Long.

expression.Bottom

*expression   * Required. An expression that returns an MiRect or MiSelectRect object.

Example

The following example performs optical character recognition (OCR) on the first image in a document, then reports the coordinates of the bounding rectangle of the third word in the recognized text.

Sub TestRectangleProperties()

  Dim miDoc As MODI.Document
  Dim miWord As MODI.Word
  Dim miRects As MODI.miRects
  Dim miRect As MODI.miRect
  Dim strRectInfo As String
  
  Set miDoc = New MODI.Document
  miDoc.Create "C:\document1.tif"
  
  miDoc.Images(0).OCR
  
  Set miRects = miDoc.Images(0).Layout.Words(2).Rects
  strRectInfo = "Word falls within " & miRects.Count & _
    " bounding rectangle(s)." & vbCrLf
  For Each miRect In miRects
    strRectInfo = strRectInfo & _
      " Rectangle coordinates: " & vbCrLf & _
      "  - Left: " & miRect.Left & vbCrLf & _
      "  - Right: " & miRect.Right & vbCrLf & _
      "  - Top: " & miRect.Top & vbCrLf & _
      "  - Bottom: " & miRect.Bottom
  Next
  MsgBox strRectInfo, vbInformation + vbOKOnly, _
    "Rectangle Information"
  
  Set miRect = Nothing
  Set miRects = Nothing
  Set miWord = Nothing
  Set miDoc = Nothing

End Sub

Applies to | MiRect Object | MiSelectRect Object