911 - We are having problems attaching an image on mobileComposeHtmlMail

Randy Hengst iowahengst at mac.com
Thu Jul 14 09:07:39 EDT 2016


I hesitate to comment, since I’ve only used mobileComposeMail…. but, based on that experience it looks like you have one too many [ in these lines. Shouldn’t there only be one before “type”?

put "image/png" into tAttachment[1][["type"]
put "myimagecid.png" into tAttachment[1][["name"]
put "myimagecid" into tAttachment[1][["cid"]

be well,
randy


> On Jul 14, 2016, at 7:26 AM, Todd Fabacher <tfabacher at gmail.com> wrote:
> 
> Hello All,
> 
> We are trying to attach an image in an HTML email and
> use mobileComposeHtmlMail to send them on mobile devices. Here is the code.
> It send s the email, but the images are NOT attaching. We tried base64
> encoding, but that did not work. We are on a tight deadline and can't get
> this to work.
> 
> Help is MUCH appreciated.
> 
> -->HTML Code
> 
> -- Put image cid
> 
> put "<img src='cid:myimagecid'/> " after tBody
> 
> -->HTML Code
> 
> -- Get image binary data
> 
> put getGraphImage() into tChartImg
> 
> -- Put image binary data into attachment
> 
> put tChartImg into tAttachment[1]["data"]
> 
> -- Put image type into attachment
> 
> put "image/png" into tAttachment[1][["type"]
> 
> -- Put image name into attachment
> 
> put "myimagecid.png" into tAttachment[1][["name"]
> 
> put "myimagecid" into tAttachment[1][["cid"]
> 
> -- Pass tAttachment parameter to mobileComposeHtmlMail function
> 
> mobileComposeHtmlMail tSubject, tSendTo, , ,tBody, tAttachment
> 
> 
> Thanks Todd & Team
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode




More information about the use-livecode mailing list