C# Development - Send SMS Message With Computer

in #utopian-io7 years ago

With this program you can send sms from your computer to your phone, your friends.

The vianett.com site is used for the sms codes of the program

Design of the program
Tasarım.png


Message TextBox and Form1 Properties

Ayarlar1.png
Ayarlar2.png


Code and website we will use for Sms
sms code.png


Right-click in the References area, select Add Reference, tick in the System.Web library, and click OK.
references.png


SMS Codes
kod ekranı.png


Result
Sonuç.png


https://github.com/ShanksTaicho/Send-SMS-message

Code list used in the project

 private void btnSend_Click(object sender, EventArgs e)
{
using (System.Net.WebClient client = new System.Net.WebClient())
{
try
{
string url = " http://smsc.vianett.no/v3/send.ashx?" +
"src=" + txtPhoneNumber.Text + "&" +
"dst=" + txtPhoneNumber.Text + "&" +
"msg=" + System.Web.HttpUtility.UrlEncode(txtMessage.Text, System.Text.Encoding.GetEncoding("ISO-8859-1")) + "&" +
"username=" + System.Web.HttpUtility.UrlEncode(txtUsername.Text) + "&" +
"password=" + System.Web.HttpUtility.UrlEncode(txtPassword.Text);
string result = client.DownloadString(url);
if (result.Contains("OK"))
MessageBox.Show("Your message has been succesfully sent.", "Message", MessageBoxButtons.OK, MessageBoxIcon.Information);
else
MessageBox.Show("Message send failure.", "Message", MessageBoxButtons.OK, MessageBoxIcon.Information);
   
}

catch(Exception ex)
{
MessageBox.Show(ex.Message, "Message", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}



Posted on Utopian.io - Rewarding Open Source Contributors

Sort:  

Interesting Good Luck

If you encounter any problems, please feel free to comment @originalworks

The @OriginalWorks bot has determined this post by @shankstaicho to be original material and upvoted it!

ezgif.com-resize.gif

To call @OriginalWorks, simply reply to any post with @originalworks or !originalworks in your message!

Yine çok yararlı bir konu abi ellerine sağlık <3

thank for a shared .

efsane konu olmuş helal olsun

Your contribution cannot be approved because it does not follow the Utopian Rules, and is considered as plagiarism. Plagiarism is not allowed on Utopian, and posts that engage in plagiarism will be flagged and hidden forever.

I found 'almost exactly same' code by googling, here is one.

You can contact us on Discord.
[utopian-moderator]

Coin Marketplace

STEEM 0.25
TRX 0.20
JST 0.036
BTC 93600.04
ETH 3361.63
USDT 1.00
SBD 3.83