But it works here too, and returns this erro.-2 should not be running. Regards, Itamar M. Lins Jr.
"Szakáts Viktor" <harbour...@syenar.hu> escreveu na mensagem news:eaea62e3-3a36-4f55-8e59-8b9a90517...@syenar.hu... Hi Itamar, It works here. Are you sure the printer name is a valid one? Brgds, Viktor On 2009.05.27., at 12:56, Itamar Lins wrote: > Hi! > This part of my code is working, but returns this error. > > nRet := PrintFileRaw(cPrint,cArq,'Pedido') //return -2 but run ok :-( > if nRet < 1 > cMsg := 'Erro Imprimindo: ' > SWITCH nRet > CASE -1 > cMsg += "Invalid parameters passed to function" ; EXIT > CASE -2 > cMsg += "WinAPI OpenPrinter() call failed" ; EXIT > CASE -3 > cMsg += "WinAPI StartDocPrinter() call failed" ; EXIT > CASE -4 > cMsg += "WinAPI StartPagePrinter() call failed" ; EXIT > CASE -5 > cMsg += "WinAPI malloc() of memory failed" ; EXIT > CASE -6 > cMsg += "Arquivo " + cArq + " não Localizado" ; EXIT > END > MsgInfo(cMsg) //WinAPI OpenPrinter() call failed > EndIf > > Regards, > Itamar M. Lins Jr. > > > > _______________________________________________ > Harbour mailing list > Harbour@harbour-project.org > http://lists.harbour-project.org/mailman/listinfo/harbour _______________________________________________ Harbour mailing list Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour