Click or drag to resize

IMcGraphOverlayExConvertToPoly Method

Replace one or more McGraphObj instances with equivalent McGraphObjPoly instances.

Namespace:  MediaCy.IQL.Display.Overlays
Assembly:  MediaCy.IQL.Display.Overlays (in MediaCy.IQL.Display.Overlays.dll) Version: 10.0.6912.0
Syntax
VB
Function ConvertToPoly ( 
	<OptionalAttribute> ObjectsToConvert As Object
) As Object

Parameters

ObjectsToConvert (Optional)
Type: SystemObject
If given, a scalar or array of McGraphObj instances which are to be converted into McGraphObjPoly instances, if possible. If missing, the selected McGraphObj instances are converted.

Return Value

Type: Object
Either Nothing or an array of one or more McGraphObjPoly instances corresponding to the ObjectsToConvert. If no objects in ObjectsToConvert are convertable, then Nothing is returned. If any of the objects in ObjectsToConvert are convertable, then the returned array will hold the same number of objects as ObjectsToConvert (or the number of Selected objects if ObjectsToConvert is missing); in this case those ObjectsToConvert instances that could not be converted will be returned as Nothing.
Remarks
Not all types of McGraphObj instances can be converted to (i.e., replaced by) McGraphObjPoly instances. McGraphObjPoint and McGraphObjText cannot be converted, nor can any McGraphObj instance that is a member of a McGraphObjGroup. And naturally, instances of McGraphObjPoly are already of the proper type, so they also will be reported as "not-converted". Conversion proceeds in four steps: First, a McGraphOverlay.ObjectPropertyChanged( Nothing, mcmolpidCovertToPolyStarting) event is fired. Next, for each converable source McGraphObj instance, a new McGraphObjPoly instance is created, assigned coordinates, appearance and any Label. Just prior to the new McGraphObjPoly being completely created, the original source McGraphObj is deleted. Then the new McGraphObjPoly is notified as creation-complete. That is, the ObjectCreated event will follow follow the ObjectAboutToBeDestroyed event. Finally a McGraphOverlay.ObjectPropertyChanged( Nothing, mcmolpidCovertToPolyComplete) event is fired. The McGraphOverlay.NotifyContext during all of the events associated with the intermediate creations and deletion operations will have the mcGraphOverlayNotifyContext mcgoncFromTool and mcgoncFromUser bits clear. Note however, that either of these bits might be set during the ObjectPropertyChanged(mcmolpidCovertToPolyStarting) event, depending on the context in which the McGraphOverlayEx.ConvertToPoly call was made.
See Also