File management
Ronny Sonntag
irgendwo at nirgendwo.com
Thu Oct 16 10:11:11 EDT 2008
erict1689 schrieb:
> def closeUp():
> # Purpose: end of program housekeeping
> global empName, previousYTD, payRate, hoursWorked, recordCount,
> eof, payFile, \
> payFileUpdated, newYTD, currentPay
>
> payFile.close()
> payFileUpdated.close()
> print "\nNumber of records in the file was",recordCount
>
> any and all help is appreciated.
>
don't use global, here ist no need for.
if you need a output file so open one and use it.
def writeFile(fileName, content):
hd = open(fileName, 'wb');
hd.write(content)
hd.close
More information about the Python-list
mailing list