ADFDi Error : The remote server returned an error: (411) Length Required
JDeveloper version 11.1.2.1.0
weblogic Version 10.3.5.0
Hi All,
From ADF Desktop integration application, When the user key in username and password the system show the following error message. Please help to me how to tackle it as well as useful blogs.
Regards
KT
Error Detail:
WebException: The remote server returned an error: (411) Length Required.
Source: System
Stack:
at System.Net.HttpWebRequest.GetResponse()
at oracle.adf.client.windows.common.internet.http.ManagedHttpResponse..ctor(HttpWebRequest request)
at oracle.adf.client.windows.common.internet.http.ManagedHttpRequest.GetResponse()
at oracle.adf.client.windows.datamanager.servletrequest.SyncRequest.BeginResponse()
at oracle.adf.client.windows.datamanager.servletrequest.TamperCheckRequest.InternalCallSyncServlet()
at oracle.adf.client.windows.datamanager.servletrequest.SyncServletRequest.CallSyncServlet(Boolean retry)
at oracle.adf.client.windows.datamanager.ADFBindingContext.SendSyncServletRequest(SyncServletRequest request)
at oracle.adf.client.windows.datamanager.ADFBindingContext.CheckForTampering()
at oracle.adf.client.windows.datamanager.ADFBindingContext.PreSyncServletTamperCheck()
at oracle.adf.client.windows.datamanager.ADFBindingContext.SyncModel(BindingContainer bc, String contentType)
at oracle.adf.client.windows.datamanager.BindingContainer.Repopulate()
at oracle.adf.client.windows.datamanager.BindingContainer.SyncModel(Boolean forceSync)
at oracle.adf.client.windows.excel.runtime.uicomponent.RTActionCollection.DoInvoke(RTColumnCollection parent, String contextLabel)
In which environment is your application hosted? Are there any other network components sitting between the client and the application, such as CDN or load balancer?
It would be very helpful if you can capture the client-side HTTP traffic using some tools (e.g. Fiddler - http://www.fiddler2.com/fiddler2/), so that we can know where the "401 length required" error is sent from by looking at the header of the HTTP response of the error.
Similar Messages
-
Hi,
Any help appreciated!!
I'm getting this error: "The remote server returned an error: (401) unauthorised when I debug a provider-hosted app. I get the error on this line:
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
See code below
I created a high trust development environment following the instructions provided here:
http://msdn.microsoft.com/en-us/library/office/fp179901(v=office.15).aspx and
http://msdn.microsoft.com/library/office/fp179923
I created a provider-hosted app with the intent to:
create a SharePoint list in the appweb
Use self-signed certificate, tokenhepler.cs and sharepointcontext.cs to retrieve current user context and access on SharePoint. (No changes were made to tokenhelper.cs and sharepointcontext.cs)
retrieve list items from the SharePoint list in a button click event handler on a default.aspx of the remote web
What happens:
The app is deployed successfully to the Dev site
The SharePoint feature is deployed and activated
The default.aspx page of the remote web loads
The error (see image) is returned on clicking of the button
My environment is an on-premise SharePoint 2013 with AD and my dev box is standalone windows 8.1 running Visual Studio Professional 2013 Update 3.
The code block below is a copy of the default.aspx code-behind
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Microsoft.SharePoint.Client;
using Microsoft.IdentityModel.S2S.Tokens;
using System.Net;
using System.IO;
using System.Xml;
using System.Data;
using System.Xml.Linq;
using System.Xml.XPath;
namespace Idea.GeneratorWeb
public partial class Default : System.Web.UI.Page
SharePointContextToken contextToken;
string accessToken;
Uri sharepointUrl;
protected void Page_PreInit(object sender, EventArgs e)
Uri redirectUrl;
switch (SharePointContextProvider.CheckRedirectionStatus(Context, out redirectUrl))
case RedirectionStatus.Ok:
return;
case RedirectionStatus.ShouldRedirect:
Response.Redirect(redirectUrl.AbsoluteUri, endResponse: true);
break;
case RedirectionStatus.CanNotRedirect:
Response.Write("An error occurred while processing your request.");
Response.End();
break;
protected void Page_Load(object sender, EventArgs e)
//// The following code gets the client context and Title property by using TokenHelper.
//// To access other properties, the app may need to request permissions on the host web.
var spContext = SharePointContextProvider.Current.GetSharePointContext(Context);
//var spContext = new ClientContext("MySPDevInstance");
//spContext.Credentials = new NetworkCredential("username", "password");
//using (var clientContext = spContext.CreateUserClientContextForSPHost())
// clientContext.Load(clientContext.Web, web => web.Title);
// clientContext.ExecuteQuery();
// Response.Write(clientContext.Web.Title);
string contextTokenString = TokenHelper.GetContextTokenFromRequest(Request);
if (contextTokenString != null)
// Get context token
contextToken = TokenHelper.ReadAndValidateContextToken(contextTokenString, Request.Url.Authority);
// Get access token
sharepointUrl = new Uri(Request.QueryString["SPAppWebUrl"]);
accessToken = TokenHelper.GetAccessToken(contextToken, sharepointUrl.Authority).AccessToken;
// Pass the access token to the button event handler.
Button1.CommandArgument = accessToken;
protected void Button1_Click(object sender, EventArgs e)
// Retrieve the access token that the Page_Load method stored
// in the button's command argument.
string accessToken = ((Button)sender).CommandArgument;
if (IsPostBack)
sharepointUrl = new Uri(Request.QueryString["SPAppWebUrl"]);
// REST/OData URL section
string oDataUrl = "/_api/Web/lists/getbytitle('Diagrams In Idea Generator')/items?$select=Title,Diagram,SharingStatus";
// HTTP Request and Response construction section
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(sharepointUrl.ToString() + oDataUrl);
request.Method = "GET";
request.Accept = "application/atom+xml";
request.ContentType = "application/atom+xml;type=entry";
request.Headers.Add("Authorization", "Bearer " + accessToken);
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
// Response markup parsing section
XDocument oDataXML = XDocument.Load(response.GetResponseStream(), LoadOptions.None);
XNamespace atom = "http://www.w3.org/2005/Atom";
XNamespace d = "http://schemas.microsoft.com/ado/2007/08/dataservices";
XNamespace m = "http://schemas.microsoft.com/ado/2007/08/dataservices/metadata";
List<XElement> entries = oDataXML.Descendants(atom + "entry")
.Elements(atom + "content")
.Elements(m + "properties")
.ToList();
var entryFieldValues = from entry in entries
select new
Character = entry.Element(d + "Title").Value,
Actor = entry.Element(d + "Diagram").Value,
CastingStatus = entry.Element(d + "SharingStatus").Value
GridView1.DataSource = entryFieldValues;
GridView1.DataBind();
Any ideas what I might be doing wrongHi ,
Use the below code
Public string GetAccessToken(){
string sharePointSiteUrlHost = Page.Request["SPHostUrl"].Tostring();
string AccessToken = tokenHelper.GetS2SAccessTokenWithWindowsIdentity(sharePointSiteUrlHost, Request.LogonUserIdentity);
return accessToken;
Than initialize the ClientCOntext with the below Method
private static ClientContext GetClientContextWithAccessTokenString(string targetUrl, object accessToken)
ClientContext clientContext = new ClientContext(targetUrl);
clientContext.AuthenticationMode = ClientAuthenticationMode.Anonymous;
clientContext.FormDigestHandlingEnabled = false;
clientContext.ExecutingWebRequest +=
delegate(object oSender, WebRequestEventArgs webRequestEventArgs)
webRequestEventArgs.WebRequestExecutor.WebRequest.UserAgent = "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)";
webRequestEventArgs.WebRequestExecutor.RequestHeaders["Authorization"] =
"Bearer " + accessToken;
return clientContext;
use this clientCOntext and it will work.
Do not use
SharePointContextProvider
Whenever you see a reply and if you think is helpful,Vote As Helpful! And whenever you see a reply being an answer to the question of the thread, click Mark As Answer -
Hi Everyone,
I am connecting to an external web service from my biztalk application through a dynamic send port.
When my biztalk application is trying to send the request message to the web service through the send port, I am getting the following error :
The remote server returned an error: (403) Forbidden.
The external web service team have provided a certificate and a private key to install in my server.
I have installed the certificate by double click the .pfx file using the private key and have added the certificate in the host ProcessHostx64.
Still i am getting the same error.
Can someone help on this issue ?
Many Thanks,
Anand
S B AThe Private Key should be installed under the user running the BizTalk Server Host. Please confirm that you have done this?
If so, try to make this work in a small .NET test Application before porting it to BizTalk, so that you can confirm that you do have sufficient credentials to call the Service.
Morten la Cour -
hi,
im configured the as2 partner setup as per this http://msdn.microsoft.com/en-us/library/bb246129(BTS.20).aspx.
but when im process file , then file try hit partner url goes dyhradated state,then failed. then i got below error.
The remote server returned an error: (500) Internal Server Error.
please any help..
Thanks500 server error could be due to anyone of the following reasons:
Party configuration is wrong. Party properties/configurations have to be discussed upfront with the source/destination system and have to be in-line with
them.
Certificates have to be deployed in correct folders based on certificate types like private/public/signed etc.
Firewall (or network components) has to be opened accordingly for parties(systems) to interact. This change has to be done at the both the levels, source and destination.
If you receive it through HTTPReceive.dll (may uses this for AS2), you have to check its configurations.
Also 500 error, could occur even if your BizTalk artifacts has not been configured/deployed/enabled properly.
If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply. -
WCF Error: The remote server returned an error: Not Found
I have a windows phone8 app that utilizes a azure WCF service. I added the Servicereference to my project,when i call the service method it executes fine but getting the following error after executing:
System.ServiceModel.CommunicationException: The remote server returned an error: Not Found
Here's the code where my error's occuring (the error occurs on the 2nd line of code within the method(the line that contains "_result =
public string EndSendMessage(System.IAsyncResult result) {
object[] _args = new object[0];
string _result = ((string)(base.EndInvoke("SendMessage", _args, result)));
return _result;
Any idea why this is happening?
Thanks.Hi Narendramacha,
It may be have more than one possibility reasons. Did you try the service URL in the phone/emulator Internet Explorer to be sure the url is accessible ? About this error, I found some solutions , please refer to :
1.maxStringContentLength: http://stackoverflow.com/a/5185678
2.FireWall: http://stackoverflow.com/a/15594388
Please try it. Any results, please let me know.
Regards,
Will
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
Hi,
I am unable to create a folder on FTP location via c# code.
I am getting the following error message:
The remote server returned an error: (530) Not logged in.
I have attached my code for your reference.
FtpWebRequest myFtpWebRequest = null;
myFtpWebRequest = (FtpWebRequest)FtpWebRequest.Create(new Uri(ftpfullpath + "/" + dirName));
myFtpWebRequest.Method = WebRequestMethods.Ftp.MakeDirectory;
myFtpWebRequest.UseBinary = true;
myFtpWebRequest.Credentials = new NetworkCredential(strUserNameFTP, strPasswordFTP);
FtpWebResponse response = (FtpWebResponse)myFtpWebRequest.GetResponse();
response.Close();
Note : value of ftpfullpath is "ftp://ftpxxxtest.com:21"Hi,
Still I am getting the error:
Exception 1 : The remote server returned an error: (502) Command not implemented
I am getting this error message when I tried to find Whether the folder exist on FTP location. I will attached the code for your review.
try
string ftpServerIP = "ftp://ftptestcon.sathiyajeba.com:21";
string strUserNameFTP = "dev_backup";
string strPasswordFTP = "india@2090";
string ftpfullpath = ftpServerIP ;
var request = (FtpWebRequest)WebRequest.Create(ftpfullpath + "/" + directory);
request.Credentials = new NetworkCredential(strUserNameFTP.Normalize(), strPasswordFTP.Normalize());
request.EnableSsl = true;
request.Method = WebRequestMethods.Ftp.GetDateTimestamp;
FtpWebResponse response = (FtpWebResponse)request.GetResponse();
return true;
catch (WebException ex)
WriteLog("Error on FtpDirectoryExists : " + ex.Message.ToString());
FtpWebResponse response = (FtpWebResponse)ex.Response;
if (response.StatusCode == FtpStatusCode.ActionNotTakenFileUnavailable)
WriteLog("Error on FtpDirectoryExists : Test-1");
return false;
else
WriteLog("Error on FtpDirectoryExists : Test-2");
return false;
Exception 2: The remote server returned an error: (530) Not logged in.
Getting this error message when I tried to create a folder on FTP location. Attached the source code for your review.
string ftpServerIP = "ftp://ftptestcon.sathiyajeba.com:21";
string strUserNameFTP = "dev_backup";
string strPasswordFTP = "india@2090";
string ftpfullpath = strServerFTP;
try
FtpWebRequest myFtpWebRequest = null;
myFtpWebRequest = (FtpWebRequest)FtpWebRequest.Create(new Uri(ftpfullpath + "/" + dirName));
myFtpWebRequest.Method = WebRequestMethods.Ftp.MakeDirectory;
myFtpWebRequest.UseBinary = true;
myFtpWebRequest.Credentials = new NetworkCredential(strUserNameFTP.Normalize(), strPasswordFTP.Normalize());
FtpWebResponse response = (FtpWebResponse)myFtpWebRequest.GetResponse();
response.Close();
return true;
catch (Exception ex)
WriteLog("Error on CreateDirectory : " + ex.Message.ToString());
return false;
Could you please any help me to resolve this exception?
Thanks,
Sathiya Jeba C -
I get this error once I click the "Test Connection" button in the OData Connection manager. I am working against an O365 SharePoint List. I will add that I have this working just fine when running it from my Windows 8 workstation using Visual Studio
2013.
On my Windows 2012 R2 Server, using Visual Studio 2013 is wen I encounter the error so I know I have the connection settings correct. I am going against the same SP list using the same credentials. The only difference is when running on Server
2012 vs. Winodws 8 workstation. I don't know if there are some other security settings that need to be applied.
I will also add that I can access on premise list successfully, I am only having this issue with O365 List.
Any help would be appreciated. Thanks.
JimIt might be due to the “Microsoft Online Services Authentication” NOT set to true.
See
http://whitepages.unlimitedviz.com/2014/03/using-the-odata-source-connector-with-sharepoint-online-authentication/
Arthur
MyBlog
Twitter -
Error: The remote server returned an error: (409) Conflict
I'm doing a simple receiver with EventProcessorHost and getting this error.
It happens when I debug receiver.
The ProcessEventsAsync() has a loop by events. Seems the loop processes the first event then throw this exception. The strange thing is, the loop can be started with events collection from one item, but the loop is trying to process the second item...
Leonid Ganeline [BizTalk MVP]I've found out the issues. Yes, they are two, my bad. The main issue was in custom code, irrelevant to EventHub. I faulted by localize the error to the EventHub, but it was not it.
The secondary issue was, I called GetBytes() second time on the EventData body, which is not allowed. Body can be read only once!
Leonid Ganeline [BizTalk MVP] -
Power BI analysis services connector - the remote server returned an error (403)
Hi all, does any one have any suggestions what to try to identify the configuration problem I have?
I have, a SSAS 2012 tabular instance with SP2, there is a database on the instance with a read role with everyone assigned permissions.
When configuring the Power BI analysis services connector, at the point where you enter Friendly Name, Description and Friendly error message, when you click next I receive the error "The remote server returned an error (403)."
I've tested connecting to the database from Excel on a desktop and connect fine.
I don't use a "onmicrosoft" account so don't have that problem to deal with.
We use Power BI Pro with our Office 365. As far as I can tell that part is working ok as I pass that stage of the configuration with a message saying connected to Power BI.
The connector is installed on the same server as tabular services, its a Win2012 Standard server. The tabular instance is running a domain account that is the admin account for the instance (this is a dev environment) that account is what I've used in the
connector configuration. It's also a local admin account. There is no gateway installed on the server.
Any help would be greatly appreciated, thanks, Brian
Brian SearleBrian-
One other common issue I've seen is the UPN not quite matching. Log onto the SSAS server as the user who's logged into Power BI. Then open a command prompt and run:
whoami /upn
Hopefully the UPN it says will match your EffectiveUserName test and will match exactly how you're signing into the Power BI site.
If that doesn't work, your best bet is to go to
http://support.powerbi.com/ and click Contact Support and describe this situation and someone from the Power BI support team should get in touch with you to troubleshoot.
http://artisconsulting.com/Blogs/GregGalloway -
Getting "The remote server returned an error 503 server unavailable" in azure web jobs
I have created one web
job - on demand schedule under azure web site. This web jobs contains .execmd(i.e.)
Console Application.
I am retrieving the data from SQL Azure database and uploaded the data in sharepoint online lists. (i.e.)I have uploaded the data to several(7) lists in each subsites. I have 3 subsites.
I am getting this error "The remote server returned an error 503 server unavailable", while uploaded the data into lists.
Full Error Message:
Message - The remote server returned an error 503 server unavailable.
StackTrace - at System.Net.HttpWebRequest.GetResponse()
> cc525c: INFO] at Microsoft.SharePoint.Client.SPWebRequestExecutor.Execute()
> cc525c: INFO] at Microsoft.SharePoint.Client.ClientRequest.ExecuteQueryToServer(ChunkStringBuilder sb)
> cc525c: INFO] at Microsoft.SharePoint.Client.ClientRequest.ExecuteQuery()
> cc525c: INFO] at Microsoft.SharePoint.Client.ClientRuntimeContext.ExecuteQuery()
> cc525c: INFO] at Microsoft.SharePoint.Client.ClientContext.ExecuteQuery()
This is not occur every time. Some time i didn't get any error data successfully uploaded in share point online list.
Totally 4 hours taken uploaded the data into list for completed all 3 subsites.
If anyone know how to resolve this.
Thanks,
A.RamuHi,
Per my understanding, there is an issue when uploading data from SQL Azure database to a SharePoint list in Online environment.
For narrowing down the issue, I suggest you create a Console Application in Visual Studio without accessing the SQL Azure database and upload some sample data to the same SharePoint
list to see if the issue still occurs intermittently.
Thanks
Patrick Liang
TechNet Community Support
Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
[email protected] -
The remote server returned an error: (401) Unauthorized
We are attempting to upload a file to SharePoint on Office 365 and get the following error:
The remote server returned an error: (401) Unauthorized.
We also tried using NetworkCredentials and that got the following error: The remote server returned an error: (404) Not Found.
The code is shown below.
Any idea on to fix this error?
public
void uploadDocument(string
siteurl, string username,
SecureString securepassword,
string domain,
string filestreamPath =
"NewDocument.docx",
string serverRelativeUrl =
"/Shared Documents/NewDocument.docx")
ClientContext context =
new
ClientContext(siteurl);
//context.Credentials = new NetworkCredential(username, securepassword, domain);
context.Credentials = new
SharePointOnlineCredentials(username, securepassword);
using (FileStream
fileStream =
new
FileStream(filestreamPath,
FileMode.Open))
ClientOM.File.SaveBinaryDirect(context,
serverRelativeUrl, fileStream, true);Yes, it has access. In fact, it has no problem getting the site properties using the code below. It is just when I am uploading a file that the error occurs.
public Web getProperties(string
siteurl, string username,
SecureString securepassword)
Web web = null;
// Starting with ClientContext, the constructor requires a URL to the
// server running SharePoint.
ClientContext context = new ClientContext(siteurl);
// The SharePoint web at the URL.
web = context.Web;
// We want to retrieve the web's properties.
context.Load(web);
// Execute the query to the server.
context.Credentials = new SharePointOnlineCredentials(username, securepassword);
context.ExecuteQuery();
return web; -
Risport Service: The remote server returned an error: (502) Bad Gateway
Hi All.
I am using the CUCM (System version: 6.1.3.2000-1) Risport function to get device information.
When trying to connect to the service (https://<CUCM_IP>:8443/realtimeservice/services/RisPort) I receive the folowing error:
The remote server returned an error: (502) Bad Gateway
When entering the same URL into the browser on the same application server I get a Security Alert, user prompt and eventually the expected screen. So the service is running, but somhow I can not connect to it using the application.
Does anyone know how to solve this?
Thanks in advanceIt is an C#.NET Windows Service.
I have solved "the problem". The service was running with "local system account". That user did not had the right proxy rights to connect to the CUCM service.
So I changed the Windows Service user to the account that I use to login on that machine (with the right proxy rights) and now it is working ;-)
I figured this out because when I logged into that machine, with my account, I could connect to the CUCM service without any problems with my browser. -
Hi
I configured forms based authentication mode in Sharepoint 2013 site. When i tried to log in with windows authentication prompt it throws the following error
The remote server returned an error: (500) Internal Server Error
[WebException: The remote server returned an error: (500) Internal Server Error.] System.Net.HttpWebRequest.GetResponse() +8548300 System.ServiceModel.Channels.HttpChannelRequest.WaitForReply(TimeSpan timeout) +111 [ProtocolException:
The content type text/html; charset=utf-8 of the response message does not match the content type of the binding (application/soap+msbin1). If using a custom encoder, be sure that the IsContentTypeSupported method is implemented properly. The first
1024 bytes of the response were: '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
How to fix this issue?
Regards,
SivaDid you create a new web application or modify an existing web application?
I would start by checking the ULS logs, maybe there is an incorrect setting within one of the web.config files, or SQL permissions.
Also, as suggested above, check application pools are running.
This blog post is a great guide for setting up FBA, check it through to make sure you haven't missed any steps:
http://blogs.technet.com/b/ptsblog/archive/2013/09/20/configuring-sharepoint-2013-forms-based-authentication-with-sqlmembershipprovider.aspx -
i have developed a very small web service and which is hosted along with our web site. our webservice url is
http://www.bba-reman.com/Search/SearchDataIndex.asmx
web service code
namespace WebSearchIndex
#region SearchDataIndex
/// <summary>
/// SearchDataIndex is web service which will call function exist in another library for part data indexing
/// </summary>
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[System.ComponentModel.ToolboxItem(false)]
// To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line.
// [System.Web.Script.Services.ScriptService]
public class SearchDataIndex : System.Web.Services.WebService
//public AuthHeader ServiceAuth=null;
public class AuthHeader : SoapHeader
public string Username;
public string Password;
#region StartIndex
/// <summary>
/// this function will invoke CreateIndex function of SiteSearch module to reindex the data
/// </summary>
[WebMethod]
public string StartIndex(AuthHeader auth)
string strRetVal = "";
if (auth.Username == "Admin" && auth.Password == "Admin")
strRetVal = SiteSearch.CreateIndex(false);
else
SoapException se = new SoapException("Failed : Invalid credentials",
SoapException.ClientFaultCode,Context.Request.Url.AbsoluteUri,new Exception("Invalid credentials"));
throw se;
return strRetVal;
#endregion
#endregion
when i was calling that web service from my win apps using
HttpWebRequest
class then getting error The remote server returned an error: (500) Internal Server Error
here is code of my win apps from where i am calling web service
string strXml = "";
strXml = "<s:Envelope xmlns:s='http://schemas.xmlsoap.org/soap/envelope/'><s:Body><StartIndex xmlns='http://tempuri.org/' xmlns:i='http://www.w3.org/2001/XMLSchema-instance'><auth><Username>joy</Username><Password>joy</Password></auth></StartIndex></s:Body></s:Envelope>";
string url = "http://www.bba-reman.com/Search/SearchDataIndex.asmx";
HttpWebRequest req = (HttpWebRequest)WebRequest.Create(url);
req.Method = "POST";
req.ContentType = "text/xml";
req.KeepAlive = false;
req.ContentLength = strXml.Length;
StreamWriter streamOut = new StreamWriter(req.GetRequestStream(), System.Text.Encoding.ASCII);
streamOut.Write(strXml);
streamOut.Close();
StreamReader streamIn = new StreamReader(req.GetResponse().GetResponseStream());
string strResponse = streamIn.ReadToEnd();
streamIn.Close();
i am just not being able to understand when this line execute
StreamReader streamIn = new StreamReader(req.GetResponse().GetResponseStream());
then getting the error The remote server returned an error: (500) Internal Server Error
not being able to understand where i made the mistake. mistake is in the code of web service end or in calling code?
help me to fix this issue. thanksHi Mou,
I just tried your win app code about calling web service, but failed. I got the 500 error after I called your service:
The error message I quoted from Fiddler:
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><soap:Fault><faultcode>soap:Client</faultcode><faultstring>System.Web.Services.Protocols.SoapException: Failed : Invalid credentials ---> System.Exception: Invalid credentials
--- End of inner exception stack trace ---
at BBAReman.WebSearchIndex.SearchDataIndex.StartIndex(AuthHeader auth)</faultstring><faultactor>http://www.bba-reman.com/Search/SearchDataIndex.asmx</faultactor><detail /></soap:Fault></soap:Body></soap:Envelope>
I am not totally sure that error occurred by the authentication. But I suggest you can try to add this service into your project using this method below:
1.right click the Reference and select Add Service Reference
2.input your service link and click "Go"
And you can use this service as the following:
private async void callService()
ServiceReference1.SearchDataIndexSoapClient client =new ServiceReference1.SearchDataIndexSoapClient();
var Str= await client.StartIndexAsync(new ServiceReference1.AuthHeader { Username = "Admin", Password = "Admin" });
Please try it.
Regards,
Will
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
error while executing script for sharepoint online (office 365) - the remote server returned an error: (503) server unavailable.
I am creating many site collections reading records from sharepoint list using powershell in sharepoint online tenant (office 365).
Few site collections are created and then getting above error so this error record will be skipped then few succeeding record processed then again getting error.
pattern is like:
success
success
success
success
Error
success
success
success
success
success
success
error
successHi,
As it is an online environment, to troubleshoot this issue in an easier way, I suggest you contact Office 365 Support to see if there is any useful information in
the log files in the server side:
https://support.office.com/en-us/article/Contact-Office-365-for-business-support-32a17ca7-6fa0-4870-8a8d-e25ba4ccfd4b?ui=en-US&rs=en-US&ad=US
Best regards
Patrick Liang
TechNet Community Support
Maybe you are looking for
-
Word 2008 - "read only" after ML install
I installed Mountain Lion today and now when I try to creat a new folder in Word 2008 it will only allow a "read only" folder (which helps me none) and then won't even let me insert a folder name! I searched the communities and haven't seen this iss
-
Starting Desktop impossible in Virtual Box: Unable to delete desktop
Hi @all, another recurring problem is that some desktop won't start. Trying to do so neither implicitly via regular login nor explicitly via VDI-Manager works. Error throuwn by the Job says: The desktop VDI3-VBox-Adm01 could not be deleted from host
-
Same Files are Updating Every Time I Sync
Hey I was wondering if anyone could help me out. Every time I plug my iPhone in to sync the same 169 music files update through iTunes. I was wondering if there was anyway to stop this being that it's taking so long to sync because of this.
-
Google layer stretched underneath Theme and UserDefined FOI when get IMAGE
Here's my situation. We have Google Maps tile layer and some Theme-Based FOI Layers (SDO srid 3785). Everything looks good on the map. But on the picture of this map (requested by function mapview.getMapImageURL in oraclemap.js) the Google layer is s
-
HT2486 Where and how can you see how many members in a group?
I wish to know how many members I have in my group. In the old address book I just clicked on the group and it told me but now it doesnt. PLease help