Please explain this how to solve this issue.
This is my code: --
public class Job : IJob
{
public void SendSMS()
{
var Message = "Server Response " + new SmsProcessor().SendSMS("918800604269", "hi this is test SMS API by MVC 02-01-2018", SmsProcessor.SmsType.SendSMS_MType);
{
message.Subject = "Message Subject test";
message.Body = "Message body test at " + DateTime.Now;
using (SmtpClient client = new SmtpClient
{
EnableSsl = true,
Host = "smtp.gmail.com",
Port = 587,
})
{
client.Send(message);
}
}
}
public static bool IsTaskDone = false;
public void Execute(IJobExecutionContext context)
{
SendSMS();
}
}