I get an int object is not callable TypeError when I execute this. But I don't understand why.
parser = optparse.OptionParser("usage: %lines [options] arg1") parser.add_option("-l", "--lines", dest="lines", default=10, type="int", help="number of lines") parser.add_option("-t", "--topbottom", dest="topbottom", default="T", type="str", help="T(op) or B(ottom)") (options, args) = parser.parse_args() if len(args) != 1: parser.error("incorrect number of arguments") lines=options.lines tb=options.topbottom Dirk lines(args[0],topbottom=tb,maxi=lines) -- http://mail.python.org/mailman/listinfo/python-list