When point groups are deleted through the UI and then recreated via code with the same name the criteria such as the excluded point number list is included. It would be nice if it started with a clean slate once created and not keep around deleted point group.
The work around is to clear the QueryBuilder
AeccPointGroup pointGroup = aeccApp.AeccDoc.PointGroups.Add(pointGroupName.ToUpper());
pointGroup.QueryBuilder.Clear();
Hi Chris -
Yes, you need to call the IAeccPointGroupQueryBuilder:: Clear()
BTW - PointGroup is also exposed in .NET API.
Cheers,
Partha Sarkar
Autodesk
I'm fairly certain I went with the COM because I couldn't figure out the GetQuery() and SetQuery() in .NET. Yep, trying to get a query string and can't seem to figure it out.
Hi;
Read this about point groups queries. (And generally about COGO points...)
Cheers;
Its there -
Thanks,
Partha
Yep, but it's really hard to figure out how to get the object since it does not return a StandardPointGroupQuery or a CustomPointGroupQuery directly. One has to be smart enough to do something like this:
StandardPointGroupQuery ptGroupQuery = (StandardPointGroupQuery)ptGroup.GetQuery();
Even then I have no real idea the difference between StandardPointGroupQuery and CustomPointGroupQuery, at least based on the API documentation.