torbjornd

Changing coordinates

Discussion created by torbjornd on Nov 28, 2012
Hi.
I'm trying to create an add-in which changes the coordinates of the features inside a selected featurelayer. I've written the add-in in C#. I'm doing this because I have to change the extent (position) of my features due to confidenciality. My add-in takes an input integer and multiplies the coordinates of every features. If the layers is a polyline, it loops through all of the polylines' points. So far, so good. The add-in seems to be working, as the resulting layers has changed position.

The problem is that the featurelayer extent is wrong. When I zoom to the layerextent, it zooms out to the extent of both my new layer and the old one. The layer extent is:

Top:66502540,599000
Left: 591326,580000
Right: 6084954,500000
Bottom: 6633323,599900

I think there are something wrong with the "left" value.

How do I correct this? Is there any functions in ArcObjects which I should use to update the extent? Or does anyone have any other good solutions for changing the position/coordinates?

Regards,
Torbjørn

Outcomes