Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to store x-coordinates and y-coordinates of a polygon feature in a table. But, i am getting an error message: Item not found in this collection. The code is like this:

 pFeature = pFeatureCursor.NextFeature  
 If Not (pFeature Is Nothing) Then  
   pPointCollection = pFeature.Shape  
   For lPnt = 0 To (pPointCollection.PointCount - 1)  
     ppolyrow = ptable.CreateRow()  
     ppolyrow.Value(coorxind) = pPointCollection.Point(lPnt).X()  
     ppolyrow.Value(cooryind) = pPointCollection.Point(lPnt).Y()  

The error comes in this following line of code:

ppolyrow.Value(coorxind) = pPointCollection.Point(lPnt).X()  

Any help....

share|improve this question
What does the error message say? – artwork21 Sep 5 '12 at 11:22
Thanks artwork21, ppolyrow.Value(coorxind) = Double.Parse(ppoint.X) ppolyrow.Value(cooryind)=Double.Parse(pPoint.Y) – Navish Sep 15 '12 at 9:42

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.