CMIMEENC (pdf-file to mime)

CMIMEENC (pdf-file to mime)

Postby Marc Vanzegbroeck » Thu Jan 14, 2021 3:21 pm

Hi,

A want to add a PDF-file into a xml-file with mime (base64) encoded.
How can I add this?
If I use
Code: Select all  Expand view
CMIMEENC('C:\Users\Marc\Documents\Factuur 20210005.pdf')

then the text 'C:\Users\Marc\Documents\Factuur 20210005.pdf' is converted.
Can I use memoread()? Does this also read the special characters of PDF-file?
Regards,
Marc

FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Marc Vanzegbroeck
 
Posts: 1157
Joined: Mon Oct 17, 2005 5:41 am
Location: Belgium

Re: CMIMEENC (pdf-file to mime)

Postby Giovany Vecchi » Thu Jan 14, 2021 3:45 pm

Use

cResult := Hb_base64Encode(Hb_MemoRead('C:\Users\Marc\Documents\Factuur 20210005.pdf'))
User avatar
Giovany Vecchi
 
Posts: 207
Joined: Mon Jun 05, 2006 9:39 pm
Location: Brasil


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 91 guests