HELP! HELP! Access problem to WebServices

Discussion in 'ASP .Net Web Controls' started by Farm, Apr 16, 2004.

  1. Farm

    Farm Guest

    I have written a generic proxy class for web services access
    This proxy class runs in the same server of WebService
    The class works fine if the browser runs in LAN, however it generates the following error if i access from remote machine

    -----------------------------------------------------------------------------------------------------
    Object reference not set to an instance of an object.

    Description
    An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details
    System.NullReferenceException: Object reference not set to an instance of an object

    Source Error:
    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace
    [NullReferenceException: Object reference not set to an instance of an object.]
    Farm.Web.Controls.SoapMethod.ServerExecute(String SoapHost, String SoapServer, String SoapNameSpace, HttpRequest Request, HttpSessionState Session) in SoapMethod.vb:25
    Farm.Web.Controls.ComboBox.Render(HtmlTextWriter output) in ComboBox.vb:426
    System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
    System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +72
    System.Web.UI.Control.Render(HtmlTextWriter writer) +7
    System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
    System.Web.UI.Page.ProcessRequestMain() +192
    -----------------------------------------------------------------------------------------------------

    Some server code

    With HTTPRe

    .Proxy = GlobalProxySelection.GetEmptyWebProxy()

    .ContentType = "text/xml; charset=utf-8
    .Method = "POST
    .KeepAlive = Fals

    .Credentials = CredentialCache.DefaultCredential

    Dim i As Int3

    Dim strKey As Strin

    For i = 0 To Request.Headers.Count -
    strKey = Request.Headers.GetKey(i
    AddHeader(strKey, Request.Headers(strKey)) 'utility functio
    Nex

    .CookieContainer = New CookieContaine
    .CookieContainer.GetCookies(curUri) 'get the list of cookies to send to the destination site

    Dim app As New CookieCollectio

    For i = 0 To Request.Cookies.Count -
    app.Add(CastCookie(Request.Cookies.Item(i), Request.ServerVariables("HTTP_HOST"))
    Nex

    .CookieContainer.Add(app

    End Wit

    Dim strm As System.IO.StreamWrite
    Dim XML As New System.Xml.XmlDocumen
    Dim HttpRes As HttpWebRespons

    Tr
    'Write the Request Strea
    error here------> strm = New StreamWriter(HTTPReq.GetRequestStream(), Encoding.UTF8
    ........

    -----------------------------------------------------------------------------------------------------

    The server is protected by a linux firewall without proxy

    Thank you very much !!
    Farm, Apr 16, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Julien Petit-Pasquier

    WebServices file access problem with UNC Name.

    Julien Petit-Pasquier, Jul 23, 2003, in forum: ASP .Net Security
    Replies:
    0
    Views:
    142
    Julien Petit-Pasquier
    Jul 23, 2003
  2. Mani

    Access exception in Webservices

    Mani, Jul 26, 2003, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    117
  3. Farm

    HELP! HELP! Access problem to WebServices

    Farm, Apr 16, 2004, in forum: ASP .Net Web Services
    Replies:
    2
    Views:
    127
  4. FS

    Problem with access to WebServices

    FS, Apr 21, 2004, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    112
  5. Tommy100

    restrict access to webservices

    Tommy100, Feb 9, 2006, in forum: ASP .Net Web Services
    Replies:
    1
    Views:
    145
    Josh Twist
    Feb 9, 2006
Loading...

Share This Page