Please find below code for sending SMS
/// <summary>
/// Sends SMS
/// </summary>
/// <returns> Returns true if SMS sent successfully </returns>
private bool SendSMS()
{
try
{
if (string.IsNullOrEmpty( txtSMSPhoneNumber.Text.Trim()) )
{
MessageBox.Show("Please enter Phone Number to send SMS", "SMS Validation",
MessageBoxButtons.OK, MessageBoxIcon.Information);
txtSMSPhoneNumber.Focus();
return false;
}
if (txtSMSPhoneNumber.Text.Trim() .Length < 10)
{
MessageBox.Show("Invalid Phone Number. Please enter valid Phone Number", "SMS Validation",
MessageBoxButtons.OK, MessageBoxIcon.Information);
txtSMSPhoneNumber.Focus();
return false;
}
if (string.IsNullOrEmpty( txtSMSText.Text.Trim()))
{
MessageBox.Show("Please text to SMS", "SMS Validation",
MessageBoxButtons.OK, MessageBoxIcon.Information);
txtSMSText.Focus();
return false;
}
string SMSText = txtSMSText.Text.Trim(). Replace(" ", "");
StringBuilder SMSURL = new StringBuilder();
SMSURL.Append("http:// smsoutbox.info/?user=Abm& password=abm567&PhoneNumber=91 ");
SMSURL.Append( txtSMSPhoneNumber.Text.Trim()) ;
SMSURL.Append("&Text=");
SMSURL.Append(SMSText);
SMSURL.Append("&Sender=Minacs" );
//ProcessStartInfo PSInfo = new ProcessStartInfo("http://www. google.co.in/");
//PSInfo.WindowStyle = ProcessWindowStyle.Minimized;
//PSInfo.CreateNoWindow = true;
//Process.Start(PSInfo);
Process.Start(SMSURL.ToString( ));
ShowWaiting("Sending SMS");
return true;
}
catch (Exception ex)
{
throw new Exception("Error in Function TestCustInfo.SendSMS. Error Message :- "
+ ex.Message, ex);
}
}
Hi there! This blog post could not be written any better!
ReplyDeleteGoing through this post reminds me of my previous roommate!
He always kept preaching about this. I will forward this article to him.
Pretty sure he's going to have a very good read. Thank you for sharing!
Visit my web blog: clickbank review
Can you furnish additional information on this?
ReplyDeleteHere is my homepage :: small business to start
I Preserve hearing towards the news speak just about acquiring free of charge on-line grant applications so I've been looking about for the optimal website to get one.
ReplyDeletemy page ... resources
Hi, I usually do not recognize that, if the spot of their own RSS reader.
ReplyDeleteCan you enable please:)
Feel free to visit my blog post ... billigreisen türkei
Of course, as a vital internet site and informative posts I will give it back hyperlink - Bookmark this page?
ReplyDeleteRegards
Feel free to surf to my site - affiliate
Good post: P
ReplyDeleteHere is my site urlaubsreise türkei
Asking questions are actually nice thing if you are not understanding something entirely,
ReplyDeletebut this paragraph presents good understanding yet.
Also visit my weblog ... tono ()
Nice post. I learn something totally new and challenging
ReplyDeleteon blogs I stumbleupon everyday. It will always be useful to read content from other
authors and use something from their web sites.
Visit my page :: sunken
Thanks for sharing your thoughts about rasos.
ReplyDeleteRegards
Also visit my website - dcolumn
Hi! This is kind of off topic but I need some guidance from an established blog.
ReplyDeleteIs it tough to set up your own blog? I'm not very techincal but I can figure things out pretty fast. I'm thinking about making my own but I'm not sure where to start. Do you have any points or suggestions? Cheers
Here is my web-site; watches ()
What's up to all, how is all, I think every one is getting more from this website, and your views are fastidious designed for new people.
ReplyDeleteHere is my web site - laudeer
Could you please tell on which site we need to register for this? Is it free and available in India?
ReplyDeleteThanks for sharing. This blog is so informative for providing a valuable information about sending sms api c#.
ReplyDelete