Click here to Skip to main content
12,448,563 members (52,035 online)
Rate this:
 
Please Sign up or sign in to vote.
See more: C# .NET VS2010 .NET4
I want to Send sms using Internet in c#.I tried diff. technique posted by diff. author's but was unsuccessfull. If u hav any sol. plz help Me.
Thank you
Posted 12-Feb-13 22:53pm
Comments
CHill60 13-Feb-13 4:58am
   
The trouble is if you don't post the code that "was unsuccessfull" we don't know what you've tried. You will end up with solutions that just contain links to various articles and sample code that you may have already seen. At worst someone will post a "let me google that for you" search. Try using the Improve question widget to add some more detail to your question
OriginalGriff 13-Feb-13 5:02am
   
"At worst someone will post a "let me google that for you" search"

Don't tempt me! :laugh:
CHill60 13-Feb-13 5:04am
   
I was very very tempted ... but the site was down :-(
OriginalGriff 13-Feb-13 5:06am
   
It's working now - and so is LetMeBingThatForYou. :laugh:
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 2

One approach would be to send a text message with your gmail account

using System.Net;
using System.Net.Mail;
 
public void SendTextMessage(string subject, string message, long telephoneNumer)
        {
            // login details for gmail acct.
            const string sender = "me@gmail.com";
            const string password = "mypassword4gmailacct";
 
            // find the carriers sms gateway for the recipent. txt.att.net is for AT&T customers.
            string carrierGateway = "txt.att.net";
 
            // this is the recipents number @ carrierGateway that gmail use to deliver message.
            string recipent = string.Concat(new object[]{
            telephoneNumer,
            '@',
            carrierGateway
            });
 
            // form the text message and send
            using (MailMessage textMessage = new MailMessage(sender, recipent, subject, message))
            {
                using (SmtpClient textMessageClient = new SmtpClient("smtp.gmail.com", 587))
                {
                    textMessageClient.UseDefaultCredentials = false;
                    textMessageClient.EnableSsl = true;
                    textMessageClient.Credentials = new NetworkCredential(sender, password);
                    textMessageClient.Send(textMessage);
                }
            }
        }

For a List of Sms Gateways check http://en.wikipedia.org/wiki/List_of_SMS_gateways[^]

Note: When the recipent responds to the message the message will be sent to your gmail account...Great for backups Smile | :)
  Permalink  
v4
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

Have a look at this link[^]

In particular look for the responses from AlexFeinman but especially from saslic
  Permalink  
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 3

Sending SMS using your way2sms account

Use smsClient.dll for sending sms using your way2sms account

You can download smsClient.dll from the following link

http://skdotnetdeveloper.blogspot.in/2011/09/send-sms-in-cnet.html

Add reference of this dll and use this following code for sending the sms

SmsClient.SendSms sms = new SmsClient.SendSms();
//string status=sms.send(way2smsuserid, way2smspassword, message, tonumber);
  Permalink  
Comments
charles henington 13-Feb-13 23:46pm
   
mistakenly voted a 3 and wont let me change to a 1 so consider this one a gift but the reson for this vote is that way2sms only works in India
Renju Vinod 14-Feb-13 0:37am
   
@charles henington - Actually this question is asked by "Raj Vishwakarma15425" he is in India so this code will work fine for him
Member 10332979 25-Jun-14 14:22pm
   
any help for pakistani.....?????? :(
Member 12667863 3 days ago
   
haha no help

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web01 | 2.8.160811.3 | Last Updated 13 Feb 2013
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100