You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

convert pdf file to base64

Summary:

convert pdf file to base64

Content (required):

Hello everyone. Please your support. I'm using Visual Builder and I already have the option to upload a PDF file. I must send that file through a standard API so that the PDF can be attached to the ERP. I already have the API and can now load the file on the screen, but I need to convert the PDF file to base64 so that it can be read by the API.

I am using this code in the JS: btoa(fileSet)); // fileSet is the uploaded file.

This returns me Base64 but when I open the PDF it shows that the file is damaged. This returns me Base64 but when I open the PDF it shows that the file is damaged.

Tagged:

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!