API Forum

This forum is in read-only mode.
Please refer to our API support in case you have any questions.
We can be reached at api@e-conomic.com
e-conomic API developer forum

Use API to link Document to invoice


In e-conomics web you can link a document to an invoice (by using the Link document link on the new invoice form) The linked document(s) are added to the end of the invoice pdf

Can I use the API to link documents to invoices?

If yes - then what methods/objects should I use?

When I am linking documents in the e-conomics web I can link to documents accessible via my local File Open ... dialog.

What document sources do I have access to when eventually using API for linking documents? (ftp, webDAV, my e-conomic document repository)
closed as a duplicate of: Attach PDF/Voucher to CurrentInvoice?
created Sep 10, 2012 by kejessen
50% Accept Rate

closed Feb 18, 2015 by olej
Q 2 A 1 C 1

4 Answers

Best answer

The functionality "Link document" on an invoice is currently only available via GUI.

We've taken note of your request.

Thank you.
answered Feb 6, 2015 by olej
I would like to know if this is possible also.
answered Dec 4, 2013 by rs

I'm assuming your are talking about supplier invoices which means cashbook.

if that's right, then you have to use RegisterPdfVoucher from CashBook EconomicSession object passing the file binaries, the voucher number and the cashbookentrydate date.

please find a code i used in .Net:

var pdfFile = System.IO.File.ReadAllBytes(pdfFilePath);

session.CashBook.RegisterPdfVoucher(pdfData, cashBookEntryData.VoucherNumber, cashBookEntryData.Date);


answered Dec 18, 2013 by GuCa
No I was not thinking of supplier invoices, but of my own invoices to my customers.

And actually my question is kind of outdated, because I have found out that even if I could attach files to an invoice, I would not be able to use this facility, because some of my customers receives OIOUBL invoices, and OIOUBL does not allow attached files
We need this too.
answered Feb 18, 2015 by Jens Kirk
Visma e-conomic A/S