- Jun 6, 2020
- 11,517
- 4,383
Hello everyone,
This is my first experience in B4A.
I'm trying to write a code that sends an email.
This is the code I wrote:
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Private xui As XUI
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'Private x As Int,y As Int,z As Int
Public SMTP As SMTP
End Sub
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("Layout")
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub Button1_Click
xui.MsgboxAsync("1", "B4X")
SMTP.Initialize("mail.gmail.com", 587, "dovanshelovich@gmail.com", "xxxxxxx", "SMTP")
SMTP.StartTLSMode = True
SMTP.To.Add("gilanshelovich@gmail.com")
SMTP.Subject = "asunto"
SMTP.Body = "cuerpo"
SMTP.Send
xui.MsgboxAsync("2", "B4X")
End Sub
The...
This is my first experience in B4A.
I'm trying to write a code that sends an email.
This is the code I wrote:
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Private xui As XUI
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'Private x As Int,y As Int,z As Int
Public SMTP As SMTP
End Sub
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("Layout")
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub Button1_Click
xui.MsgboxAsync("1", "B4X")
SMTP.Initialize("mail.gmail.com", 587, "dovanshelovich@gmail.com", "xxxxxxx", "SMTP")
SMTP.StartTLSMode = True
SMTP.To.Add("gilanshelovich@gmail.com")
SMTP.Subject = "asunto"
SMTP.Body = "cuerpo"
SMTP.Send
xui.MsgboxAsync("2", "B4X")
End Sub
The...
برای دیدن لینک ها باید ثبت نام کنید
برای دیدن لینک ها باید ثبت نام کنید