Purpose
Returns a region object that approximates the shape of another object. You can call this function from the MapBasic window in MapInfo Pro.
Syntax
ConvertToRegion( object )
object is the object to convert; may not be a point, line, or text object.
Return Value
A region object
Description
Retains most style attributes. Other attributes are determined by the current pens or brushes. A polyline whose first and last nodes are identical will not have the last node duplicated. Otherwise, MapInfo Pro adds a last node whose vertices are the same as the first node.
The ConvertToRegion() function returns a region object which approximates the object parameter. Thus, if the object parameter represents a rectangle, ConvertToRegion() returns a region that looks like a rectangle.
The results obtained by calling ConvertToRegion() are similar to the results obtained by choosing MapInfo Pro's Convert To Regions command on the SPATIAL tab. However, the ConvertToRegion() function does not alter the original object.
See Also: