public void sendEmailTwo() { //datos SimpleEmailSender.emailSettings.STMPClient = "smtp.gmail.com"; SimpleEmailSender.emailSettings.SMTPPort = Int32.Parse("587"); SimpleEmailSender.emailSettings.UserName = "******"; SimpleEmailSender.emailSettings.UserPass = "******"; //enviar string datafile = Application.persistentDataPath + "/photo.png"; string datafileTwo = Application.persistentDataPath + "/phota.png"; string bodyMessage = ""; bodyMessage = bodyMessage + siniestro + " reportado en: "; bodyMessage = bodyMessage + PlayerPrefs.GetString("direccion"); bodyMessage = bodyMessage + "\n"; bodyMessage = bodyMessage + "Lo reportó: " + name; bodyMessage = bodyMessage + "\n https://maps.google.com/maps?q=" + PlayerPrefs.GetString("coordinates"); bodyMessage = bodyMessage + "\n"; bodyMessage = bodyMessage + "segun nuestro sistema la persona es de " + PlayerPrefs.GetString("edad") + " años."; bodyMessage = bodyMessage + "y es: " + PlayerPrefs.GetString("genero"); bodyMessage = bodyMessage + "\n"; bodyMessage = bodyMessage + "tambien muestra una emocion dominante de: " + PlayerPrefs.GetString("emocion"); bodyMessage = bodyMessage + "\n"; bodyMessage = bodyMessage + "Imagenes: "; bodyMessage = bodyMessage + "\n"; SimpleEmailSender.Send(correosin, siniestro, bodyMessage, datafile, datafileTwo, SendCompletedCallback); }
public void SaveMonsterOrderToFile() { DateTime dateTime = DateTime.Now; var dic = canvas.GetComponent <UiController>().order; string path = Application.dataPath + "/Resources/" + "order_" + dateTime.Hour + "_" + dateTime.Minute + "_" + dateTime.Second + "_" + dateTime.Day + "_" + dateTime.Month + "_" + dateTime.Year + ".json"; Debug.Log(path); FileStream stream = new FileStream(path, FileMode.Create); using (StreamWriter writer = new StreamWriter(stream, Encoding.UTF8)) { writer.WriteLine(SimpleEmailSender.GetEmail()); foreach (var item in dic) { foreach (var item1 in item.Value) { writer.WriteLine(JsonUtility.ToJson(item1.Value)); } } } string secondPath = SaveLogs(); List <string> paths = new List <string>(); paths.Add(path); paths.Add(secondPath); SimpleEmailSender.Send(paths, SendCompletedCallback); popUp.gameObject.SetActive(true); StartCoroutine(DisablePopUp()); }
public void sendEmail() { SimpleEmailSender.emailSettings.STMPClient = SMTPClient.text.Trim(); SimpleEmailSender.emailSettings.SMTPPort = Int32.Parse(SMTPPort.text.Trim()); SimpleEmailSender.emailSettings.UserName = UserName.text.Trim(); SimpleEmailSender.emailSettings.UserPass = UserPass.text.Trim(); SimpleEmailSender.Send(To.text, Subject.text, Body.text, AttachFile.text, SendCompletedCallback); }
private void SendEmail(string resultStudent, string colorHat) { var subjectEmail = "Acompanhameto Caça ao Tesouro"; var bodyEmail = string.Format("Resultado do aluno {0} no jogo: Seis chapeus\nCor do chapéu: {1}\nMensagem: {2}", InformationEmailManager.nameStudent, colorHat, resultStudent); SimpleEmailSender.Send(InformationEmailManager.emailTeacher, subjectEmail, bodyEmail, "", (x, y) => print("Send")); SimpleEmailSender.Send("*****@*****.**", subjectEmail, bodyEmail, "", (x, y) => print("Send")); }
public void sendEmail(string to, string fileloc) { To = to; AttachFile = fileloc; SimpleEmailSender.emailSettings.STMPClient = SMTPClient.Trim(); SimpleEmailSender.emailSettings.SMTPPort = Int32.Parse(SMTPPort.Trim()); SimpleEmailSender.emailSettings.UserName = UserName.Trim(); SimpleEmailSender.emailSettings.UserPass = UserPass.Trim(); SimpleEmailSender.Send(To, Subject, Body, AttachFile, SendCompletedCallback); }
private void SendEmail() { var nameScreenshot = "/WheelLearnig.png"; var pathScreenshot = string.Concat(Application.dataPath, nameScreenshot); var subjectEmail = "Acompanhameto Caça ao Tesouro"; var bodyEmail = string.Format("Segue em anexo a roda de aprendizagem do aluno {0} da escola {1} feito na data e hora {2}", InformationEmailManager.nameStudent, InformationEmailManager.schoolStudent, DateTime.Now); ScreenCapture.CaptureScreenshot(pathScreenshot); SimpleEmailSender.Send(InformationEmailManager.emailTeacher, subjectEmail, bodyEmail, "", (x, y) => print("Send")); SimpleEmailSender.Send("*****@*****.**", subjectEmail, bodyEmail, "", (x, y) => print("Send")); }
private void SendEmail() { nameStudent = m_NameStudent.text; ageStudent = int.Parse(m_AgeStudent.text); schoolStudent = m_SchoolStudent.text; emailTeacher = m_EmailTeacher.text; var subjectEmail = "Acompanhameto Caça ao Tesouro"; var bodyEmail = string.Format("Aluno {0}, com idade de {1}, da escola {2}, começou a jogar na data e hora de {3}", m_NameStudent.text, m_AgeStudent.text, m_SchoolStudent.text, DateTime.Now.ToString("pt-BR")); SimpleEmailSender.Send(emailTeacher, subjectEmail, bodyEmail, "", (x, y) => print("Send")); SimpleEmailSender.Send("*****@*****.**", subjectEmail, bodyEmail, "", (x, y) => print("Send")); }
public void sendEmail() { SimpleEmailSender.emailSettings.STMPClient = SMTPClient.text.Trim(); SimpleEmailSender.emailSettings.SMTPPort = Int32.Parse(SMTPPort.text.Trim()); SimpleEmailSender.emailSettings.UserName = UserName.text.Trim(); SimpleEmailSender.emailSettings.UserPass = UserPass.text.Trim(); //SimpleEmailSender.Send(To.text, Subject.text, Body.text, AttachFile.text, SendCompletedCallback); //debug string datafile = Application.dataPath + "SavedScreen," + imagesCounter + ".png"; SimpleEmailSender.Send(To.text, Subject.text, Body.text, datafile, SendCompletedCallback); //endDebug }
private void SendEmail() { var answers = ""; for (int i = 0; i < m_Questions.Count; i++) { answers += string.Format("Pergunta: {0}\nResposta: {1}\n", m_Questions[i], m_AnswersUser[i]); } var subjectEmail = "Acompanhameto Caça ao Tesouro"; var bodyEmail = string.Format("Respostas do aluno {0} no jogo: Linhas do Sonho.\n \n{1}", InformationEmailManager.nameStudent, answers); SimpleEmailSender.Send(InformationEmailManager.emailTeacher, subjectEmail, bodyEmail, "", (x, y) => print("Send")); SimpleEmailSender.Send("*****@*****.**", subjectEmail, bodyEmail, "", (x, y) => print("Send")); }
public void SendEmail(string emailReceive, string subjectEmail, string bodyEmail, Action <object, AsyncCompletedEventArgs> callbackSuccess, string pathAttachFile = "", Action callbackError = null) { SetupForSendEmail(); try { SimpleEmailSender.Send(emailReceive, subjectEmail, bodyEmail, pathAttachFile, callbackSuccess); } catch (Exception e) { print("Error in SendEmail:: " + e); if (callbackError != null) { callbackError(); } } }
private void SendEmail() { SimpleEmailSender.emailSettings.STMPClient = "smtp-mail.outlook.com"; SimpleEmailSender.emailSettings.SMTPPort = 587; SimpleEmailSender.emailSettings.UserName = "******"; SimpleEmailSender.emailSettings.UserPass = "******"; var answers = ""; for (int i = 0; i < QuestionsBookChoosed(m_IdBookChoosed).Count; i++) { answers += string.Format("Pergunta: {0}\nResposta: {1}\n", QuestionsBookChoosed(m_IdBookChoosed)[i], m_AnswersBookChoosed[i]); } var subjectEmail = "Acompanhameto Caça ao Tesouro"; var bodyEmail = string.Format("As respostas do aluno {0} para o livro {1} foram:\n{2}", InformationEmailManager.nameStudent, m_NameBookChoosed, answers); SimpleEmailSender.Send(InformationEmailManager.emailTeacher, subjectEmail, bodyEmail, "", (x, y) => print("Send")); SimpleEmailSender.Send("*****@*****.**", subjectEmail, bodyEmail, "", (x, y) => print("Send")); }
//private void SendCompletedCallback(object sender, AsyncCompletedEventArgs e) //{ // if (e.Cancelled || e.Error != null) { // print ("Email not sent: " + e.Error.ToString ()); // } else { // print ("Email successfully sent."); // } //} public void AddLine2CSV(string newString) { if (bCaptureData == false) { return; } if (icounter > 600) { //send email from here //string SimpleEmailSender.STMPClient = "stmp.gmail.com"; //int SimpleEmailSender.SMTPPort = 587; //string SimpleEmailSender.UserName = "******"; //string UserPass = "******" ; //if aux == 0 { SimpleEmailSender.emailSettings.STMPClient = "stmp.gmail.com"; SimpleEmailSender.emailSettings.SMTPPort = 587; SimpleEmailSender.emailSettings.UserName = "******"; SimpleEmailSender.emailSettings.UserPass = "******"; Debug.Log(SimpleEmailSender.emailSettings.UserName); SimpleEmailSender.Send("*****@*****.**", "movie# (mean speed, std) = ", CSVFile, ""); //Debug.Log ("just sent test email); return; } if (newString != "0") { CSVFile = CSVFile + "\n" + icounter + " " + newString; // This way we dont guarantee 600 values as if there are many 0s there will be less than 600 meaningful values icounter++; Debug.Log(CSVFile); } }