setPrintToFileName (String)

Method. Sets the name of the file to which printer output is to be sent. Use the method setPrintToFileFolder to set the name of the folder in which the output file is to be stored. This method is relevant only when the printToFile property is set to True

public void setPrintToFileName(String fileName)