通过ASP发送短信 [英] Send SMS Through ASP
本文介绍了通过ASP发送短信的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何通过ASP页面发送短信?
how can i send sms Through ASP page?
推荐答案
我没有提供用户名和发件人ID b'coz你必须从sms卖家购买短信然后你会得到这个东西,授权号码是获得短信发送的号码发送
拿走所有的手机你不想在数据表中发送短信作为dt
for(int i = 0; i< dt.rows.count; i ++)>
{
string url1 =http://api.mVaayoo.com/mvaayooapi/MessageCompose?user=User_Name&senderID=ID SMS&receipientno =+ dt.Rows [i] [0 ] .ToString()+&msgtxt ='+ TextBoxName.Text +'API&state = 4;
// string strUrl =http:// api。 mVaayoo.com/mvaayooapi/MessageCompose?user=UserName&senderID=ID SMS&receipientno = AuthorizedNumber&msgtxt =这是来自mVaayoo API&state = 4的测试;
WebRequest request = HttpWebRequest.Create(url1);
HttpWebResponse resp onse =(HttpWebResponse)request.GetResponse();
Stream s =(Stream)response.GetResponseStream();
StreamReader readStream = new StreamReader(s);
string dataString = readStream.ReadToEnd();
response.Close();
s.Close();
readStream.Close();
}
I Have not Provided the UserName And sender ID b'coz u have to purchase sms from sms Seller then u will get this thing and authorized number is the number to get report of sms send
take all the mobile no u want to send sms in datatable as dt
for(int i=0;i<dt.rows.count;i++)>
{
string url1 = "http://api.mVaayoo.com/mvaayooapi/MessageCompose?user=User_Name&senderID=ID SMS&receipientno=" + dt.Rows[i][0].ToString() + "&msgtxt='"+TextBoxName.Text+"' API&state=4";
//string strUrl = "http://api.mVaayoo.com/mvaayooapi/MessageCompose?user=UserName&senderID=ID SMS&receipientno=AuthorizedNumber&msgtxt=This is a test from mVaayoo API&state=4";
WebRequest request = HttpWebRequest.Create(url1);
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
Stream s = (Stream)response.GetResponseStream();
StreamReader readStream = new StreamReader(s);
string dataString = readStream.ReadToEnd();
response.Close();
s.Close();
readStream.Close();
}
这篇关于通过ASP发送短信的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文