Overlap() function - MapBasic - 2023

MapInfo MapBasic Reference

Product type
Software
Portfolio
Locate
Product family
MapInfo
Product
MapInfo > MapBasic
Version
2023
Language
English
Product name
MapBasic
Title
MapInfo MapBasic Reference
First publish date
1985
Last updated
2023-09-12
Published on
2023-09-12T16:32:32.686312

Purpose

Returns an object representing the geographic intersection of two objects; produces results similar to MapInfo Pro's Erase Outside command. You can call this function from the MapBasic window in MapInfo Pro.

Syntax

Overlap( object1, object2 ) 

object1 is an object; it cannot be a point or text object.

object2 is an object; it cannot be a point or text object.

Return Value

An object that is the geographic intersection of object1 and object2.

Description

The Overlap() function calculates the geographic intersection of two objects (the area covered by both objects), and returns an object representing that intersection.

MapBasic retains all styles (color, etc.) of the original object1 parameter; then, if necessary, MapBasic applies the current drawing styles.

If one of the objects is linear (for example, a polyline) and the other object is closed (for example, a region), Overlap() returns the portion of the linear object that is covered by the closed object.