Dear all,
I want to intersect 2 polyline layers using vb.net arcobjects. Previously I called intersect geoprocessing tool, but I find it is too slow.
Is there a way to intersect several layers without using the gp tool?
I am using arcmap and arcobjects 10.2.2, in vb.net arcmap addin.
Thanks for attention.
Hi
The
basic command is ITopologicalOperator.Intersect
It
is working between to polylines in memory.
In
order to intersect two layers you must read the lines one by one and try to
find an intersect line on the other layer.
For
each polyline in layer1 you must select all intersect polylines in layer2
(maybe just boundary intersect) and then try to intersect them to get the geometry.
It
is not simple to write a program that will work quick and I am not sure if it
will be much quicker than the GP tool unless you have some information about
the two layers that can save some work.
Have
Fun
Mody
Thanks a lot Mody,
You mention ITopologicalOperator.Intersect working between to polylines in memory. In my case, the polylines are from aarcsde database. Is it also applicable?
Thanks.
Hi
You must open a cursor and get them from the feature class.
Mody