Dim Message As Intent
Uri = "mailto:?subject=Some Test&body=http://host/action?a=40.23"
Message.Initialize(Message.ACTION_VIEW, Uri)
StartActivity(Message)
Dim Message As Email
Message.To.Add("user@server.com") 'Email address
Message.body = "http://host/action?a=40.23" 'Email main text
Message.Attachments.Add("")
StartActivity(Message.GetIntent)
Msg = "http://host/action?a=40.23"
SMTP.Initialize("smtp.MyServer.com", 25, "user@myserver.com", "mypassword", "SMTP")
SMTP.To.Add("someone@server.com")
SMTP.Subject = "Email Test"
SMTP.Body = Msg
SMTP.Send
Is a workaround possible? Escaping, etc......
Msg = "http://host/action?a=40.23" <-- Doesn't work
Msg = "http://host/action?a= 40.23" <-- Works
Sub GPS_LocationChanged (Location1 As Location)
lon = Location1.ConvertToSeconds(Location1.Longitude)
lat= Location1.ConvertToSeconds(Location1.Latitude)
SMTP.Initialize("smtp.gmail.com", 465, "user@gmail.com", "pass", "SMTP")
SMTP.UseSSL = True
SMTP.To.Add("user@hotmail.com")
SMTP.Subject = "Subject"
SMTP.HtmlBody= True
SMTP.Body = "http://maps.google.com/staticmap?center= "&Location1.Latitude&","& Location1.Longitude&"&zoom=14&size=400x400&markers= "&Location1.Latitude&","& Location1.Longitude&"&key=12345"
SMTP.Send
End Sub
http://maps.google.com/staticmap?center@.123456789,-1.23456789&zoom&size@0x400&markers@.123456789,-1.23456789&key�345
"Rule #1: (General 8-bit representation) Any octet, except those indicating a line break according to the newline convention of the canonical (standard) form of the data being encoded, may be represented by an "=" followed by a two digit hexadecimal representation of the octet's value...."
IT WORKS !!!
I have added a single attachment, and then, URL in the mail body gets ok.
Perhaps the fine solution should be a boolean variable in the SMTP class to set or unset the header "Content-Transfer-Encoding=quoted-printable"...... Next library version Erel?
Meanwhile, I will add some "fictitious" attachment.
Thanks everybody.
'Activity module
Sub Process_Globals
' email
Dim mySMTP As SMTP
End Sub
' button callback
' send mail
mySMTP.Initialize("smtp.gmail.com", 465, "from@gmail.com", "password", "SMTP")
mySMTP.UseSSL = True
mySMTP.To.Add("to@gmail.com")
mySMTP.Subject = "Subject"
mySMTP.Body = "located at http://maps.google.com/maps?q=" & latitud & ",+" & longitud & "&iwloc=A&hl=es"
mySMTP.AddAttachment(File.DirAssets,"foo.png") ' Anything
mySMTP.Send
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?