how to send message from asp.net application

Posted by Shanky11 under ASP.NET on 2/13/2013 | Points: 10 | Views : 9147 | Status : [Member] | Replies : 7
i have to send message on mobile how can i get this requirement.
Provide me the full code not a link refer to any site




Responses

Posted by: Satyapriyanayak on: 2/13/2013 [Member] [MVP] Silver | Points: 25

Up
0
Down
http://krishnasaralanet.blogspot.in/p/sending-sms-from-aspnet-application.html
http://www.codeproject.com/Articles/387567/How-to-send-an-SMS-message-from-an-application
http://webdeveloperswall.com/dot-net/sending-sms-from-your-asp-net-application
http://www.codeproject.com/Questions/242453/How-to-send-SMS-from-asp-net-application

If this post helps you mark it as answer
Thanks

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: aswinialuri-19361 on: 2/14/2013 [Member] Starter | Points: 25

Up
0
Down
Hi

To send an sms from asp.net to mobile means
you need the gateway for that other than same as smtp server


Thanks & Regards

Mark as Answer if it helps you
Thanks&Regards
Aswini Aluri

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 2/17/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello you can try my app, i have used the dll of www.way2sms.com

First you have to register a free account on www.way2sms.com

then you can use the app

You will need 3 text boxes

1.your number
2.destination number
3.Message body

I am not pasting the Html Mark up i am just pasting the code behind and also attaching the app.

Code behind.

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SmsClient;

public partial class SendSmS : System.Web.UI.Page
{
string errdesc = "0";
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
}
}
protected void btnSend_Click(object sender, EventArgs e)
{
try
{

SendSms sms = new SendSms();
errdesc = sms.send(xtxtWay2smsNumber.Text, xtxtWay2smsPassword.Text, xtxtSMSBody.Text, xtxtRecieversMobileNumber.Text);
switch (errdesc)
{
case "1":
errdesc = "Message Sent Successfully";
xdesc.Text = errdesc;
xdesc.Visible = true;
break;
case "2":
errdesc = "No Internet Connection";
xdesc.Text = errdesc;
xdesc.Visible = true;
break;
case "3":
errdesc = "No Internet Connection or Login Number and Password Do not match.Please check Internet Connection or your Credentials";
xdesc.Text = errdesc;
xdesc.Visible = true;
break;
}
}
catch (Exception ex)
{
errdesc = ex.Message;
xdesc.Text = errdesc;
}
}
}
 Download source file

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Prabu_Spark on: 2/17/2013 [Member] Starter | Points: 25

Up
0
Down
Hi Raj.Trivedi,
I registered in way2sms, if i send msg using your code i am getting the value of errdesc=-1. What is the meaning of that.
Kindly give me the solution for this problem.

With regards,
J.Prabu.
[Email:prbspark@gmail.com]

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 2/18/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello Prabhu,

That means that the response is not being sent to way 2 sms server i will check and get back to you

Try sending sms to your Mobile Number.

If your issue is resolved please mark this as Answer

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 2/18/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello Prabhu,

Please tell me what time did you test my app,
can you try between 9:00 am - 9:00 pm IST
I believe this is a stop be way2sms.com
I will also check and get back to you by tommorrow.

Let me know

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Raj.Trivedi on: 2/18/2013 [Member] [MVP] Starter | Points: 25

Up
0
Down
Hello Prabhu,

After checking the error,its the way2sms error that has blocked any request coming outside from their domain.

Let me check if there is any other free apis

Regard's
Raj.Trivedi
"Sharing is Caring"
Please mark as answer if your Query is resolved

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response