Connecting to SSRS Web Service

I know there was a lot of discussion about how to connect to the report server web service but I tried everything I read hear and couldn't get it to work for me. So I would appreciate if someone onthis forum can make a suggestion to solve it for me.
I have SSRS SQL 2008 R2 installed in Share Point mode. and I wrote a console app to use the web service. I created two proxies one that uses a service reference to http:\\<MyServer>/ReportServer/ReportService2010.asmx and one that uses web service reference to the same URL (I wasn't sure if there is a diffrence between the two).
I tried one simple API : Create Folder(...) and the service reference gave me an error of Security problem related to Annonimous login when NTLM is expected and the Web Reference complained about Unrecognized soap action - CreateFolder.
The code and the exact wording of the error messages are below. I appreciate any help I can get regarding this:
            //ReportService2005 is a service reference to ReportService2005.asmx
            ReportService2005.ReportingService2005SoapClient client = new ReportService2005.ReportingService2005SoapClient();
            client.ClientCredentials.Windows.ClientCredential = new System.Net.NetworkCredential("myname", "mypassword", "mydomain");
            System.ServiceModel.Security.UserNamePasswordClientCredential crd = client.ClientCredentials.UserName;
            crd.Password = "mypassword";
            crd.UserName = "myname";
            ClientCredentials cr = client.ClientCredentials;
            ReportService2005.CatalogItem item1 = new ReportService2005.CatalogItem();
            client.CreateFolder(null, "xxx", "\\", null);
            //Getting the error: 
            //The HTTP request is unauthorized with client authentication scheme 'Anonymous'. 
            //The authentication header received from the server was 'NTLM'.

            //WSReportingService2005 is a web reference to ReportService2005.asmx
            WSReportingService2005.ReportingService2010 rs = new WSReportingService2005.ReportingService2010();
            rs.Credentials = new NetworkCredential("myname", "mypassword", "mydomain"); 
            rs.Url = "http://sql2008_dev/reportserver/reportservice2005.asmx";
            WSReportingService2005.CatalogItem item = null;
            item = rs.CreateFolder("xxx", "\\", null);
            //Getting the error:
            //Server did not recognize the value of HTTP Header SOAPAction: 

Open in new window

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

I do not know if this will help you in share point, but this is the kind of code we use on the web site side to view a rdl report in a PDF format.
Imports System
Imports System.IO
Imports System.Data
Imports System.Web.Services.Protocols
Imports Microsoft.SqlServer.ReportingServices2005.Execution

Partial Class RdlViewer
    Inherits System.Web.UI.Page
    Private ReportName As String = "MyReportName"
    Private DirPath As String = "MyDirectory"
    'Private objParameters(25) As Microsoft.Reporting.WebForms.ReportParameter
    Private pdfParameters(25) As ParameterValue

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        Response.Buffer = True
        Response.Expires = -1442
        Response.AddHeader("cache-control", "private")
        Response.AddHeader("pragma", "no-cache")

        If Not Page.IsPostBack Then
            Dim ServerUri As New Uri(System.Configuration.ConfigurationManager.AppSettings("ReportServerURL"))
            ReportViewer1.ServerReport.ReportServerUrl = ServerUri
            ReportViewer1.ServerReport.ReportPath = "/ServerReports/" & DirPath & "/" & ReportName

            'Go get the report parameters

            'Go run the report viewer in PDF Screen

        End If
    End Sub

    Sub PDFParams()

 'Test Parameters that you setup or add to your code
        pdfParameters(0) = New ParameterValue    'SQL2008.ParameterValue
        pdfParameters(0).Name = "CustomerID"
        pdfParameters(0).Value = "10000"    'Session("ProspectID")
        pdfParameters(1) = New ParameterValue    'SQL2008.ParameterValue
        pdfParameters(1).Name = "ProductID"
        pdfParameters(1).Value = "2000"   
        pdfParameters(2) = New ParameterValue    'SQL2008.ParameterValue
        pdfParameters(2).Name = "CustomerName"
        pdfParameters(2).Value = "John Doe"            pdfParameters(3) = New ParameterValue    'SQL2008.ParameterValue
        pdfParameters(3).Name = "CustAddress"
        pdfParameters(3).Value = "1200 West South Street"    
        pdfParameters(4) = New ParameterValue    'SQL2008.ParameterValue
        pdfParameters(4).Name = "CustCityStateZip"
        pdfParameters(4).Value = "Dallas TX 75214"    
    End Sub

    Sub asPDF()
        Dim rs As New ReportExecutionService()
        rs.Credentials = System.Net.CredentialCache.DefaultCredentials
        rs.Url = System.Configuration.ConfigurationManager.AppSettings("sql2008.ReportExecution2005")

        ' Render arguments
        Dim result As Byte() = Nothing
        Dim reportPath As String = "/" & DirPath & "/" & ReportName
        Dim format As String = "PDF"
        Dim historyID As String = Nothing
        Dim devInfo As String = "<DeviceInfo><StreamRoot>/RSWebServiceXS/</StreamRoot></DeviceInfo>"

        Dim encoding As String = Nothing
        Dim mimeType As String = Nothing
        Dim warnings As Warning() = Nothing  'SQL2008.Warning() = Nothing
        Dim streamIDs As String() = Nothing

        Dim execInfo As New ExecutionInfo
        Dim execHeader As New ExecutionHeader
        Dim extension As String = ""

        rs.ExecutionHeaderValue = execHeader

        execInfo = rs.LoadReport(reportPath, historyID)

        rs.SetExecutionParameters(pdfParameters, "en-us")
        rs.Timeout = 600 * 1000   'timeout in milliseconds (defaults to 100,000 = 100 seconds)

        result = rs.Render(format, devInfo, extension, mimeType, encoding, warnings, streamIDs)

        Response.ContentType = "application/pdf"
    End Sub

' #### this is placed in your web.config file
    <add key="ReportServerURL" value="http://gmcisvc01/ReportServer"/>
    <add key="ReportServerName" value="MyServerName"/>
      <add key="sql2008.ReportExecution2005" value="http://MyServerName/ReportServer/ReportExecution2005.asmx"/>  

Open in new window

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
This question has been classified as abandoned and is being closed as part of the Cleanup Program. See my comment at the end of the question for more details.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.