[cups.development] cupsPrintFile2 API returns -1 (v1.6.1)

Michael Sweet msweet at apple.com
Thu Nov 8 04:06:31 PST 2012


Check the value of cupsLastError() and cupsLastErrorString().

On 2012-11-08, at 7:04 AM, Charles Woloszynski <cwoloszynski at gmail.com> wrote:

> I am new to using the CUPS API and I hope someone can help me.
> 
> I have a program that is submitting a PDF to CUPS for printing. Since the printer may be remote, I am using cupsPrintFile2 with the http parameter.
> 
> When I do this, I *always* get back a -1.  The job prints (yeah!) but I think I have something wrong since I don't think that I should always get back a -1 as the jobID.  
> 
> My call is really simple:
> 
> jobId = cupsPrintFile2(http, destination, jobName, "title", 0, NULL);
> 
> Any thoughts?  Did I need to include some job option to get back the jobID?
> 
> The remote CUPS server is running on OSX, if that matters.
> 
> Thanks in advance,
> 
> Charlie
> 
> 
> _______________________________________________
> cups-dev mailing list
> cups-dev at easysw.com
> http://lists.easysw.com/mailman/listinfo/cups-dev

__________________________________________________
Michael Sweet, Senior Printing System Engineer, PWG Chair





More information about the cups mailing list