On Thu, 1 Jul 1999, Jay, Dylan wrote: If your external method is responsible of returning the binary file then something like this might work: def generateFile(self,RESPONSE): ' ' RESPONSE['content-type']='application/octet-stream' bin_data=generate_data() ## the generating function return bin_data Pavlos