0

I have really been struggling with Inuit QuickBooks desktop. I have built a lovely c# windows form for my client to interact with QuickBooks desktop version. Everything works really well except:

I create invoices etc. But once created I need to use the clients QuickBooks invoice as a .pdf to attach to an email.

I can't find anywhere that can do a programatic save for the pdf once I create an invoice, to save it to the file structure.

I can see a lot of questions but nobody seems to have done it. Has anyone else had this problem and what was the solution?

Dan Atkins
  • 378
  • 1
  • 7
  • 21
  • i found this which might help? https://stackoverflow.com/questions/20942830/how-do-i-retrieve-a-pdf-of-an-invoice-in-quickbooks-api and this https://developer.intuit.com/app/developer/qbo/docs/api/accounting/most-commonly-used/invoice#get-an-invoice-as-pdf – traveler3468 Jun 30 '19 at 07:46
  • Thanks Andrew.. that second on is QuickBooks online, which won't work:( the first one I'll explore. Thanks!! – Dan Atkins Jun 30 '19 at 08:01
  • Actually.. that post is from 2014 and the link in it is a 404:( maybe it just can't be done, but as I say to my Devs - there's always a way. May not be perfect but always a way.. – Dan Atkins Jun 30 '19 at 08:03
  • That’s no good, perhaps there is some sort of a render that will return a byte array you can use? – traveler3468 Jun 30 '19 at 08:37
  • Yup it's returns the invoice as XML.. I may have to resort to using interop and recreate the template in word but that seems crazy!! – Dan Atkins Jun 30 '19 at 08:51

1 Answers1

0

I create a PDF from the C# application using DevExpress XtraReports tool and it's designed to look exactly like a QuickBooks invoice. Then I call the method that saves it as a PDF. You can also use Crystal Reports for Visual Studio or Microsoft RDLC Report Designer for a free tool.

If you must send it from Quickbooks, the only option you have is to set the IsToBeEmailed property and then email it in QB from the File-SendForms menu.

jjthebig1
  • 629
  • 7
  • 12
  • Thanks. Can the second option be done programatically from the application? It sounds like maybe I could set up an email for the application to send to itself and then save it back to the file structure. – Dan Atkins Jul 18 '19 at 16:23