已鎖定 Execute URL from VS 2010

  • 13 มิถุนายน 2555 13:19
     
     

    Dear All,

    I want execute an URL.

    This URL used to send SMS.

    here the URL:

    http://Surbakti:surbaktiTest@sms.Surbakti.com:8080/api/single/?from=Surbakti&msisdn=2132324&message=Please+Open+Your+Email

    I have Try with this:

    Imports System.Net
    Imports System.Net.WebClient

    Dim request As HttpWebRequest
    Dim response As HttpWebResponse

     request = CType(WebRequest.Create(url), HttpWebRequest)
     response = CType(request.GetResponse(), HttpWebResponse)

    I have try this one:

     request = DirectCast(WebRequest.Create(url), HttpWebRequest)
     response = DirectCast(request.GetResponse(), HttpWebResponse)

    with 2 method above, I got error: HTTP status 401: Unauthorized.

    what the i miss?

    how can i get send the sms from that link?

    Help Me Please.

    Thanks

    Surbakti


ตอบทั้งหมด