3

I am trying to create a feature class in memory but I am not sure how to use the syntax.

My code looks like this:

FC = arcpy.CreateFeatureclass_management("", "in_memory/FC", "POLYGON", "", "DISABLED",
                                         "DISABLED", Coordinate_System, "", "0", "0", "0")

Basically I seem to have problem defining the "out_path".

5

I realized what was wrong. See the correct code here:

FC = arcpy.CreateFeatureclass_management("in_memory", "FC", "POLYGON", "", "DISABLED", "DISABLED", Coordinate_System, "", "0", "0", "0")
  • Accept your answer with the checkbox! – BERA Jun 7 at 8:30
0

According to the document working with in memory workspace in arcmap office site. the code below should work, tested in arcmap 10.3:

memory_fc = arcpy.CreateFeatureclass_management("in_memory", "feat", "Polygon")
memory_fc_path = memory_fc[0] # this is the path of the featureclass created .

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.