• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    Visual Basic Customization

    Reply
    Active Contributor
    Posts: 26
    Registered: ‎11-02-2006

    Getboundingbox returning 0,0,0

    155 Views, 2 Replies
    11-02-2006 02:18 AM
    I have stumbled upon a large problem in a script I am currently writing.

    The routine basically checks for overlapping layers - it does this by copying a reference polygon to a region and doing a series of subtractions to work out how much (if any) of the polygon overlaps another one.

    The script works perfectly if the reference polygon is contained completely within another (if it is smaller), or if the reference polygon overlaps the other. HOWEVER, if the polygons have vertices which touch more than once (eg they are the same shape, or share a common series of vertices) then when I run the getboundingbox command, the arrays minExt and maxExt both return 0,0,0.

    Is this a limitation with the getboundingbox command, and does anybody have any ideas on how to fix this problem?

    Thanks in advance.

    -Tuoni
    Please use plain text.
    New Member
    Posts: 2
    Registered: ‎04-18-2007

    Re: Getboundingbox returning 0,0,0

    04-19-2007 01:22 AM in reply to: Tuoni
    I had the same problem.

    I changed the declaration from

    ' This is in the vba examples
    Dim startPoint(0 To 2) As Double
    Dim endPoint(0 To 2) As Double

    to

    Dim startPoint As Variant
    Dim endPoint As Variant

    and it now works fine

    Thierry
    Please use plain text.
    Contributor
    Posts: 20
    Registered: ‎11-23-2009

    Re: Getboundingbox returning 0,0,0

    12-24-2011 05:08 AM in reply to: Tuoni

    I had the same problem with polyline but the declarations changes it realy helped.

    Thanks Thierry.

     

    Dominik

    Please use plain text.