Message 1 of 3
Screen update become slow when using GetSplitCurve() with DBObject.HangOverTo()
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Good evening everyone. I have a question.
I have below code to split an original curve into 2 new curves then hangover 1 of them with original curve.
Point3dCollection splitPnts = new Point3dCollection();
splitPnts.Add(trimPnt);
using (DBObjectCollection splitCurvs = memCurv.GetSplitCurves(splitPnts))
{
//baseEd.WriteMessage($"\nSplit curves 's number : {splitCurvs.Count}");
//baseEd.WriteMessage($"\nSplit curves 's point : X = {splitPnts[0].X} , Y = {splitPnts[0].Y}");
//Find closet points :
Point3d cloPnt1 = ((Curve)splitCurvs[0]).GetClosestPointTo(stdPnt, false);
Point3d cloPnt2 = ((Curve)splitCurvs[1]).GetClosestPointTo(stdPnt, false);
if (cloPnt1.DistanceTo(trimPnt) <= KRTolerance)
memCurv.HandOverTo(splitCurvs[1], true, true);
else
memCurv.HandOverTo(splitCurvs[0], true, true);
}
The problem is after the command is finish , the original curve is still the same and i have to drag my mouse about 1~2 seconds for screen update .
I tried to use Autodesk.AutoCAD.Internal.Utils.SetFocusToDwgView();
But it didn't work . Please help .
Thanks in advance !