日期:2014-05-17  浏览次数:20828 次

下面这段代码改成ASP VBS怎么写
<%@   LANGUAGE=JScript   %>
<HTML>
<HEAD>
<TITLE> Active   SMS   -   Send   SMS </TITLE>
</HEAD>
<BODY>
<H1> Send   SMS   Message   Request </H1>

<P>
<%
var   ActiveSMS   =   Server.CreateObject( "Intellisoftware.ActiveSMS ");

var   PhoneNumber   =   Request( "PhoneNumber ")
var   MessageText   =   Request( "MessageText ")

var   MessageId   =   ActiveSMS.SendUnicodeMessage(   PhoneNumber,   MessageText,   15000);
var   Status   =   ActiveSMS.GetSendStatus(MessageId);

switch   (   Status   )
{
case   2   :   //jsSent
case   9   :   //jsSentNotConfirmed
Response.Write   (   "Message   has   been   sent "   );
break;
case   7   :   //jsErrTimeout
Response.Write   (   "Message   not   sent,   Server   too   busy   [Non-Queued   Mode] "   );
break;
case   3   :   //jsErrNumberInvalid
Response.Write   (   "Message   not   sent,   Invalid   Number "   );
break;
case   0   :   //jsPending
case   1   :   //jsProcessing
Response.Write   (   "Message   has   been   queued "   );
break;
case   4   :   //jsErrNetworkFailure
Response.Write   (   "Message   not   sent,   Failure   reported   by   phone   network "   );
break;
case   5   :   //jsErrPhoneCommsError
Response.Write   (   "Message   not   sent,   Error   communicating   with   handset "   );
break;
case   10   :   //jsDeliveryFailed
Response.Write   (   "Message   delivery   failed "   );
break;
default   :
Response.Write   (   "Message   not   sent,   Internal   error   occured   (see   EventLog) "  

);
break;
}
%>
</P>

</BODY>
</HTML>


把上面的代码写改ASP   VBS怎么写。



------解决方案--------------------
<%@ LANGUAGE=VBScript %>
<HTML>
<HEAD>
<TITLE> Active SMS - Send SMS </TITLE>
</HEAD>
<BODY>
<H1> Send SMS Message Request </H1>

<P>
<%
Dim ActiveSMS
ActiveSMS = Server.CreateObject( "Intellisoftware.ActiveSMS ")

Dim PhoneNumber, MessageText
PhoneNumber = Request( "PhoneNumber ")
MessageText = Request( "MessageText ")

Dim MessageId, Status
MessageId = ActiveSMS.SendUnicodeMessage( PhoneNumber, MessageText, 15000)
Status = ActiveSMS.GetSendStatus(MessageId)

Select Case Status
Case 2 : 'jsSent
Response.Write ( "Message has been sent " )
Case 9 : 'jsSentNotConfirmed
Response.Write ( "Message has been sent " )
Case 7 : 'jsErrTimeout
Response.Write ( "Message not sent, Server too busy [Non-Queued Mode] " )
Case 3 :