Using revMail

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
sierradean
Posts: 4
Joined: Tue Feb 02, 2016 6:57 pm

Using revMail

Post by sierradean » Tue Feb 23, 2016 7:17 pm

I need to be able to attach a card saved as a PDF to the revMail on the device. Right now I am able to save the card PDF to my desktop, then put a table into the email, but I want to be able to attach the PDF to the email through live code rather than saving it to the desktop. This is what I have right now:

Code: Select all

on mouseUp
   ask file "Save PDF as:" with "Results.pdf" if it is empty then exit mouseUp
   open printing to PDF it
   print card "Orientation" of stack "Untitled 1" into the printRectangle
   print break
   print card "P-TA" of stack "Untitled 1" into the printRectangle
   print break
   print card "RetroGrade" of stack "Untitled 1" into the printRectangle
   print break
   print card "Concentration" of stack "Untitled 1" into the printRectangle
   print break
   print card "Memory" of stack "Untitled 1" into the printRectangle 
   close printing
   revMail "livecodemobile@runrevcom",,"Daily Symptom Log", field "TestScore"
end mouseUp
Does anyone know what to do? Thanks.

Klaus
Posts: 14182
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Using revMail

Post by Klaus » Tue Feb 23, 2016 7:41 pm

Hi Dean,

1. welcome to the forum! :D

2. Add a CR after "ask file..."
...
ask file "Save PDF as:" with "Results.pdf"
if it is empty then exit mouseUp
...
3. Unfortunately "revMail" does not support attachments.
On a Mac you can maybe use an AppleScript, no idea of Windows.


Best

Klaus

Post Reply