manual selection as input parameter for a script

Discussion created by oscarjavier04 on Sep 20, 2013

I  need a arcpy  script to process data from a selection, it's made manually in arcmap.
the selection is part of a mesh, to print data from a specified field.

Can i put a selection made ??????manually as input parameter for a script?

until now, I have a script that processes the selection stored in a layer that is displayed in the TOC

 #import arcpy module
import arcpy

# Load the MXD  default document
mxd = arcpy.mapping.MapDocument("CURRENT")

# Define the TOC default Data Frame
df = arcpy.mapping.ListDataFrames(mxd, "Capas")[0]

#access to the target (mesh selection), stored in a layer,
#By selecting the corresponding layer located on the TOC
fc = arcpy.mapping.ListLayers(mxd,"",df)[0]

#define of the field to consult.
field = "idMalla"

print "campo idMalla: "
# query  for reading  a specified field.
cursor = arcpy.SearchCursor(fc)
for row in cursor:

# delete memory
del mxd, df