Problem with SDK v1.1 sample...

Ask a Question related to ASP.NET General, Design and Development.

  1. #1

    Default Problem with SDK v1.1 sample...

    I'm having trouble with the VB MathServiceClient sample in the SDK (v1.1).
    When I compiled the sample it created the proxy class file
    (MathService.wsdl). All other samples work OK, so I don't think it's
    permission related.....

    Exception Details: System.Net.WebException: The request failed with HTTP
    status 401: Unauthorized.

    Source Error:

    Line 59:
    <System.Web.Services.Protocols.SoapDocumentMethodA ttribute("http://tempuri.o
    rg/Subtract", RequestNamespace:="http://tempuri.org/",
    ResponseNamespace:="http://tempuri.org/",
    Use:=System.Web.Services.Description.SoapBindingUs e.Literal,
    ParameterStyle:=System.Web.Services.Protocols.Soap ParameterStyle.Wrapped)>
    _
    Line 60: Public Function Subtract(ByVal A As Single, ByVal B As
    Single) As Single
    Line 61: Dim results() As Object = Me.Invoke("Subtract", New
    Object() {A, B})
    Line 62: Return CType(results(0),Single)
    Line 63: End Function

    Source File: <pathToSrc>\MathService.vb Line: 61

    Stack Trace:

    [WebException: The request failed with HTTP status 401: Unauthorized.]

    System.Web.Services.Protocols.SoapHttpClientProtoc ol.ReadResponse(SoapClient
    Message message, WebResponse response, Stream responseStream, Boolean
    asyncCall) +1294
    System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
    methodName, Object[] parameters) +218
    MathServiceVB.MathService.Subtract(Single A, Single B) in
    <pathToSrc>\MathService.vb:61
    _ASP.mathserviceclient_aspx.Submit_Click(Object Sender, EventArgs E) +318
    System.Web.UI.HtmlControls.HtmlInputButton.OnServe rClick(EventArgs e)
    +108

    System.Web.UI.HtmlControls.HtmlInputButton.System. Web.UI.IPostBackEventHandl
    er.RaisePostBackEvent(String eventArgument) +57
    System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
    sourceControl, String eventArgument) +18
    System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +33
    System.Web.UI.Page.ProcessRequestMain() +1277



    Guest

  2. Similar Questions and Discussions

    1. The way to run an sample.
      I installed Flash Media Server 2, Flash 5, Extension Manager, Dreamweaver 8 both in "C:\Program Files\Macromedia" directory. I uncompressed...
    2. Problem with local installation of the flex store sample.
      I've downloaded and installed the flex store sample. I unpacked the zip file into a c:\jrun\servers\cfusion\cfusion-ear\cfusion-war\flexstore...
    3. Sample application problem
      Dear Sir, I installed the flash media server trial. I tried some samples downloaded the developing center and find some problem: 1,"Using File...
    4. Here you have a sample
      Without more specifics I can show you how to get the data. This is assuming a lot because I am confused about what you want to do. Here is what I...
    5. UDF Problem (to_char() migration sample)
      Hi, I have build the UDF sample TO_CHAR(timestamp, dateformat). It built successfully but, on executing the function I got following message: ...
  3. #2

    Default Re: Problem with SDK v1.1 sample...

    If this is the only WSDL (web services) example you have tried, it probably
    is permisssions related. The 1.1 Framework locks many things down, by
    default, that 1.0 left open. We found a way to tweak the machine.config file
    to allow web services to work. It is a separate tag for GET and POST
    implementations.

    --
    Gregory A. Beamer
    MVP; MCP: +I, SE, SD, DBA
    Author: ADO.NET and XML: ASP.NET on the Edge

    ************************************************** **************************
    ****
    Think Outside the Box!
    ************************************************** **************************
    ****
    <.> wrote in message news:%23ZKZNDWQDHA.2676@TK2MSFTNGP10.phx.gbl...
    > I'm having trouble with the VB MathServiceClient sample in the SDK (v1.1).
    > When I compiled the sample it created the proxy class file
    > (MathService.wsdl). All other samples work OK, so I don't think it's
    > permission related.....
    >
    > Exception Details: System.Net.WebException: The request failed with HTTP
    > status 401: Unauthorized.
    >
    > Source Error:
    >
    > Line 59:
    >
    <System.Web.Services.Protocols.SoapDocumentMethodA ttribute("http://tempuri.o
    > rg/Subtract", RequestNamespace:="http://tempuri.org/",
    > ResponseNamespace:="http://tempuri.org/",
    > Use:=System.Web.Services.Description.SoapBindingUs e.Literal,
    > ParameterStyle:=System.Web.Services.Protocols.Soap ParameterStyle.Wrapped)>
    > _
    > Line 60: Public Function Subtract(ByVal A As Single, ByVal B As
    > Single) As Single
    > Line 61: Dim results() As Object = Me.Invoke("Subtract", New
    > Object() {A, B})
    > Line 62: Return CType(results(0),Single)
    > Line 63: End Function
    >
    > Source File: <pathToSrc>\MathService.vb Line: 61
    >
    > Stack Trace:
    >
    > [WebException: The request failed with HTTP status 401: Unauthorized.]
    >
    >
    System.Web.Services.Protocols.SoapHttpClientProtoc ol.ReadResponse(SoapClient
    > Message message, WebResponse response, Stream responseStream, Boolean
    > asyncCall) +1294
    > System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
    > methodName, Object[] parameters) +218
    > MathServiceVB.MathService.Subtract(Single A, Single B) in
    > <pathToSrc>\MathService.vb:61
    > _ASP.mathserviceclient_aspx.Submit_Click(Object Sender, EventArgs E)
    +318
    > System.Web.UI.HtmlControls.HtmlInputButton.OnServe rClick(EventArgs e)
    > +108
    >
    >
    System.Web.UI.HtmlControls.HtmlInputButton.System. Web.UI.IPostBackEventHandl
    > er.RaisePostBackEvent(String eventArgument) +57
    > System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
    > sourceControl, String eventArgument) +18
    > System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +33
    > System.Web.UI.Page.ProcessRequestMain() +1277
    >
    >
    >

    Cowboy \(Gregory A. Beamer\) Guest

  4. #3

    Default Re: Problem with SDK v1.1 sample...

    Care to share that information?


    Guest

  5. #4

    Default Re: Problem with SDK v1.1 sample...

    Thanks anyhow; I figured it out. I had to manually config the Quickstarts
    and I neglected to make the sample in question an app in IIS.


    Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139