Search Results

Search found 4060 results on 163 pages for '400 the cat'.

Page 3/163 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Bad Request (400): Why?

    - by ProfK
    Why do I get a 400 - bad request error using the following URL? It is encoded using Server.UrlEncode. The actual path query parameter is C:\Development\Chase\Exports\ChaseExport-090312073930.zip http://localhost:50199/Common/Forms/Export_Stream.aspx%3fpath%3dC%3a%5CDevelopment%5CChase%5CExports%5CChaseExport-090312073930.zip

    Read the article

  • LinkedIn with Pecl OAuth: "got a 400, expected HTTP/1.1 20X or a redirect"

    - by CharlesS
    I have Pecl OAuth with PHP5 on a Debian box and I try to authenticate to LinkedIn. When calling; OAuth-getAccessToken('https://api.lin...')\n#1 I get; PHP Fatal error: Uncaught exception 'OAuthException' with message 'Invalid auth/bad request (got a 400, expected HTTP/1.1 20X or a redirect)' I have tried it from scratch and I have tried the PHP API wrappers that are available and (ofcourse, because they use OAuth Pecl ext) have all the same problem. I read somewhere it might be the timestamp on the server, but I synched that up with ntpdate; it does that quite often now, so the offset with the timeservers is almost 0. What else can it be? Thanks

    Read the article

  • Bad http connection (400) from Simple Native Iphone App to test .net Web Service

    - by leo
    Dear all, I have written a simple hello world .net web service which will accept 2 parameters and return the parameters as a string. The web service is hosted by IIS on a windows xp pc. I am able to access the web service using safari on the iphone simulator, successfully tested the operation using HTTP POST by clicking the "invoke" button. However, when I use the native app on the iphone simulator, I keep getting a bad http connection error 400 on the IIS log. I have tested my native app with http://viium.com/WebService/HelloWorld.asmx and it works. I have already added Does anyone know what is wrong? Is it some settings that have not configured correctly? Thank you very much in advance.

    Read the article

  • Facebook publish HTTP Error 400 : bad request

    - by Abhishek
    Hey I am trying to publish a score to Facebook through python's urllib2 library. import urllib2,urllib url = "https://graph.facebook.com/USER_ID/scores" data = {} data['score']=SCORE data['access_token']='APP_ACCESS_TOKEN' data_encode = urllib.urlencode(data) request = urllib2.Request(url, data_encode) response = urllib2.urlopen(request) responseAsString = response.read() I am getting this error: response = urllib2.urlopen(request) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2.py", line 124, in urlopen return _opener.open(url, data, timeout) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2.py", line 389, in open response = meth(req, response) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2.py", line 502, in http_response 'http', request, response, code, msg, hdrs) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2.py", line 427, in error return self._call_chain(*args) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2.py", line 361, in _call_chain result = func(*args) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2.py", line 510, in http_error_default raise HTTPError(req.get_full_url(), code, msg, hdrs, fp) urllib2.HTTPError: HTTP Error 400: Bad Request Not sure if this is relating to Facebook's Open Graph or improper urllib2 API use.

    Read the article

  • [PHP] DOMDocument load on a page returning 400 Bad Request status

    - by PeteWilliams
    Hiya, I'm trying to use the Last.fm API for an application I'm creating, but am having some problems with validation. If an API request gives an error it returns a code and message in the response XML like this: <lfm status="failed"> <error code="6">No user with that name</error> </lfm> However, the request also returns an HTTP status of 400 (or in some cases 403) which DOMDocument considers an error and so then refuses to parse the XML. Is there any way round this, so that I can retrieve the error code and message? Thanks Pete

    Read the article

  • I get a 400 Bad Request error while using django-piston

    - by Cheezo
    Hello, I am trying to use Piston to provide REST support to Django. I have implemented my handlers as per the documentation provided . The problem is that i can "read" and "delete" my resource but i cannot "create" or "update". Each time i hit the relevant api i get a 400 Bad request Error. I have extended the Resource class for csrf by using this commonly available code snippet: class CsrfExemptResource(Resource): """A Custom Resource that is csrf exempt""" def init(self, handler, authentication=None): super(CsrfExemptResource, self).init(handler, authentication) self.csrf_exempt = getattr(self.handler, 'csrf_exempt', True) My class (code snippet) looks like this: user_resource = CsrfExemptResource(User) class User(BaseHandler): allowed_methods = ('GET', 'POST', 'PUT', 'DELETE') @require_extended def create(self, request): email = request.GET['email'] password = request.GET['password'] phoneNumber = request.GET['phoneNumber'] firstName = request.GET['firstName'] lastName = request.GET['lastName'] self.createNewUser(self, email,password,phoneNumber,firstName,lastName) return rc.CREATED Please let me know how can i get the create method to work using the POST operation?

    Read the article

  • 400 error when submitting tumblr post (ruby on rails)

    - by Matenia Rossides
    I am having a bit of an issue with getting tumblr working within a rails app. This is the snippet of code which results in a 400 error (meaning that there was an incorrect parameter) @postcontent = @post.content.gsub(/<\/?[^>]*>/, "") post = Tumblr::Post.create(:email => 'valid@email', :password => 'mypassword', :type => 'video', :embed = @post.video_html, :caption = @postcontent) I have checked the API docs and checked my code and code content being rendered, and it still does not want to work. The funny thing is that it worked previously. It was working about a week ago. Has something changed with tumblr?

    Read the article

  • 400 bad request when calling a WCF service via jQuery/Ajax in a IIS7 server

    - by Max
    This is what the IIS log says: 2012-12-12 16:35:44 W3SVC1 server001 76.229.32.109 POST /Dashboard/svc/RunJob.svc/RunJob/ExecuteJob - 80 - 76.229.32.109 HTTP/1.1 Mozilla/4.0+(compatible;+MSIE+8.0;+Windows+NT+6.0;+WOW64;+Trident/4.0;+SLCC1;+.NET+CLR+2.0.50727;+.NET+CLR+3.0.30729;+.NET+CLR+3.5.30729) ASP.NET_SessionId=poxpqp45rv2m3tuflzckix45 http ://server001/Dashboard/RunJob.aspx server001 400 0 0 2444 1423 1934 I have maxReceivedMessageSize set to a very high number. The weird thing is that the same code works in the lab but it wont work in production. Both environments (lab and production) are using the same web.config file. Any ideas? Thank you

    Read the article

  • Error 400 in urllib2 when using cookies

    - by Hempage
    I've had some success using a different method to load cookies, but now I'm wanting to use the cookielib.MozillaCookieJar method to open a cookies.txt file. Here's the snippet of code that does this. cookieJar=MozillaCookieJar() cookieJar.load(argv[2]) After creating an HTTPCookieProcessor opener, and installing it, whenever I use urlopen, I get an HTTP 400 error. However, if I don't use a CookieJar, the urlopen method succeeds (though the response doesn't contain the data I need). I'm not sure whether the cookies.txt file is malformed, or whether there's something else going on.

    Read the article

  • mod_rewrite per-dir redirection returning a 400

    - by Eaterrust
    I moved my images directory to a different folder, and now I want to redirect all images requests from that folder to the new one. I do not have access to the main configuraion file, so I'm doing this in a .htaccess. I tried this, and it works:     RewriteCond %{REQUEST_URI} old_dir/.+.(jpg|png|gif)$     RewriteRule old_dir/(.+[^/]+..+)$ $1 [L,PT] But since they have permanently moved, I want to do a proper redirect, so I added the [R] flag, like this:      %{REQUEST_URI} old_dir/.+.(jpg|png|gif)$     RewriteRule old_dir/(.+[^/]+..+)$ $1 [L,PT,R] But the server gets confused, and returns a 400, so I looked at the log file, and this is what happens:     strip per-dir prefix: C:/wamp/www/natrazyle/old_dir/images/banner.jpg - old_dir/images/banner.jpg     applying pattern 'old_dir/(.+[^/]+..+)$' to uri 'old_dir/images/banner.jpg'     rewrite 'old_dir/images/banner.jpg' - 'images/banner.jpg'     add per-dir prefix: images/banner.jpg - C:/wamp/www/natrazyle/images/banner.jpg     explicitly forcing redirect with http://localhost/C:/wamp/www/natrazyle/images/banner.jpg As you can see, the full local path gets added after localhost I know I'm doing something wrong, I just can't figure it out myself. Any help would be greatly appreciated...

    Read the article

  • Why my shell program wont open the file got as argument in function "cat"

    - by anna karenina
    I included the code below, sorry to bother you with so much code. Argument parsing is ok, i checked it out with watches. I've put some printfs to check out where the problem may be and it seems that it wont open the file cat receives as argument. i called from shell like "cat -b file" #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <string.h> #define TRUE 0 #define FALSE 1 void yes(int argc, char *argv[]); int cat(int argc, char *argv[]); //#include "cat.h" //#include "yes.h" //#include"tee.h" char buf[50],c[10], *p2,*p, *pch; int count; char *matrix[20]; void yes(int argc, char *argv[]) { int i; // if (argc >= 2 && *argv[1] == '-') // { //printf("ERROR!"); //} //if (argc == 1) // { while (1) if (puts("y") == EOF) { perror("yes"); exit(FALSE); } // } while (1) for (i = 1; i < argc; i++) if (fputs(argv[i], stdout) == EOF || putchar(i == argc - 1 ? '\n' : ' ') == EOF) { perror("yes"); exit(FALSE); } //exit(TRUE); } int main(int argc, char *argv[]) { //p=(char *)malloc(sizeof(char)*50); do { fprintf (stderr, "$ "); fgets (buf,50,stdin); p=buf; fprintf (stderr, "Comanda primita de la tastatura: "); fputs (buf, stderr); int i=0,j=0; //strcpy(p,buf); strcpy(c,"\0"); while (buf[i] == ' ') { i++; p++; } if (buf[i] == '#') fprintf (stderr, "Nici o comanda, ci e un comentariu!\n"); else { j=0; while (buf[i] != ' ' && buf[i] != '\n') { i++; j++; } strncpy (c,p,j); fprintf (stderr, "%s\n",c); if (strcmp (c,"yes") == 0) { p2 = p+j+1; pch = strtok (p2," "); count = 0; while (pch != NULL) { //printf ("%s\n",pch); matrix[count] = strdup(pch); pch = strtok (NULL, " "); count++; } yes(count, matrix); fprintf (stderr, "Aici se va executa comanda yes\n"); } else if (strcmp (c,"cat") == 0) { p2 = p+j+1; pch = strtok (p2," "); count = 0; while (pch != NULL) { //printf ("%s\n",pch); matrix[count] = strdup(pch); pch = strtok (NULL, " "); count++; } cat(count,matrix); fprintf (stderr, "Aici se va executa comanda cat \n"); } else if (strcmp (c,"tee") == 0) { //tee(); fprintf(stderr, "Aici se va executa comanda tee\n"); } fprintf (stderr, "Aici se va executa comanda basename\n"); strcpy(buf,"\0"); } } while (strcmp(c, "exit") != 0); fprintf (stderr, "Terminat corect!\n"); return 0; } int cat(int argc, char *argv[]) { int c ; opterr = 0 ; optind = 0 ; char number = 0; char squeeze = 0; char marker = 0; fprintf(stderr,"SALUT< SUNT IN FUNCTIZE>\n"); while ((c = getopt (argc, argv, "bnsE")) != -1) switch (c) { case 'b' : number = 1; break; case 'n' : number = 2; break; case 'm' : marker = 1; break; case 's' : squeeze = 1; break; case 'E' : marker = 1; break; } if (optind + 1 != argc) { fprintf (stderr, "\tWrong arguments!\n") ; return -1 ; } FILE * fd = fopen (argv[optind], "r"); printf("am deschis fisierul %s ",argv[optind]); if (fd == NULL) { printf("FISIER NULL asdasdasdasdasd"); return 1; } char line[1025]; int line_count = 1; while (!feof(fd)) { fgets(line, 1025, fd); printf("sunt in while :> %s",line); int len = strlen(line); if (line[len - 1] == '\n') { if(len - 2 >= 0) { if(line[len - 2] == '\r') { line[len - 2] = '\0'; len -= 2; } else { line[len - 1] = '\0'; len -= 1; } } else { line[len - 1] = '\0'; len -= 1; } } if (squeeze == 1 && len == 0) continue; if (number == 1) { fprintf (stdout, "%4d ", line_count); line_count++; } else if (number == 2) { if (len > 0) { fprintf (stdout, "%4d ", line_count); line_count++; } else fprintf (stdout, " "); } fprintf(stdout, "%s", line); if (marker == 1) fprintf(stdout, "$"); fprintf(stdout, "\n"); } fclose (fd); return 0 ; }

    Read the article

  • WCF Restful services getting error 400 (bad request) when post xml data

    - by Wayne Lo
    I am trying to self host a WCF services and calling the services via javascript. It works when I pass the request data via Json but not xml (400 bad request). Please help. Contract: public interface iSelfHostServices { [OperationContract] [WebInvoke(Method = "POST", UriTemplate = INFOMATO.RestTemplate.hello_post2,RequestFormat = WebMessageFormat.Xml, ResponseFormat = WebMessageFormat.Xml, BodyStyle = WebMessageBodyStyle.Wrapped)] Stream hello_post2(string helloString); } Server side code: public Stream hello_post2(string helloString) { if (helloString == null) { WebOperationContext.Current.OutgoingResponse.StatusCode = System.Net.HttpStatusCode.BadRequest; return null; } WebOperationContext.Current.OutgoingResponse.StatusCode = System.Net.HttpStatusCode.OK; return new MemoryStream(Encoding.UTF8.GetBytes(helloString)); } JavaScript: function testSelfHost_WCFService_post_Parameter() { var xmlString = "<helloString>'hello via Post'</helloString>"; Ajax_sendData("hello/post2", xmlString); } function Ajax_sendData(url, data) { var request = false; request = getHTTPObject(); if (request) { request.onreadystatechange = function() { parseResponse(request); }; request.open("post", url, true); request.setRequestHeader("Content-Type", "text/xml; charset=utf-8"); charset=utf-8"); request.send(data); return true; } } function getHTTPObject() { var xhr = false; if (window.XMLHttpRequest) { xhr = new XMLHttpRequest(); } else if (window.ActiveXObject) {...} }

    Read the article

  • AS 400 Performance from .Net iSeries Provider

    - by Nathan
    Hey all, First off, I am not an AS 400 guy - at all. So please forgive me for asking any noobish questions here. Basically, I am working on a .Net application that needs to access the AS400 for some real-time data. Although I have the system working, I am getting very different performance results between queries. Typically, when I make the 1st request against a SPROC on the AS400, I am seeing ~ 14 seconds to get the full data set. After that initial call, any subsequent calls usually only take ~ 1 second to return. This performance improvement remains for ~ 20 mins or so before it takes 14 seconds again. The interesting part with this is that, if the stored procedure is executed directly on the iSeries Navigator, it always returns within milliseconds (no change in response time). I wonder if it is a caching / execution plan issue but I can only apply my SQL SERVER logic to the AS400, which is not always a match. Any suggestions on what I can do to recieve a more consistant response time or simply insight as to why the AS400 is acting in this manner when I was using the iSeries Data Provider for .Net? Is there a better access method that I should use? Just in case, here's the code I am using to connect to the AS400 Dim Conn As New IBM.Data.DB2.iSeries.iDB2Connection(ConnectionString) Dim Cmd As New IBM.Data.DB2.iSeries.iDB2Command("SPROC_NAME_HERE", Conn) Cmd.CommandType = CommandType.StoredProcedure Using Conn Conn.Open() Dim Reader = Cmd.ExecuteReader() Using Reader While Reader.Read() 'Do Something End While Reader.Close() End Using Conn.Close() End Using

    Read the article

  • HTTP Error: 400 when sending msmq message over http

    - by dontera
    I am developing a solution which will utilize msmq to transmit data between two machines. Due to the seperation of said machines, we need to use HTTP transport for the messages. In my test environment I am using a Windows 7 x64 development machine, which is attempting to send messages using a homebrew app to any of several test machines I have control over. All machines are either windows server 2003 or server 2008 with msmq and msmq http support installed. For any test destination, I can use the following queue path name with success: FORMATNAME:DIRECT=TCP:[machine_name_or_ip]\private$\test_queue But for any test destination, the following always fails FORMATNAME:DIRECT=HTTP://[machine_name_or_ip]/msmq/private$/test_queue I have used all permutations of machine names/ips available. I have created mappings using the method described at this blog post. All result in the same HTTP Error: 400. The following is the code used to send messages: MessageQueue mq = new MessageQueue(queuepath); System.Messaging.Message msg = new System.Messaging.Message { Priority = MessagePriority.Normal, Formatter = new XmlMessageFormatter(), Label = "test" }; msg.Body = txtMessageBody.Text; msg.UseDeadLetterQueue = true; msg.UseJournalQueue = true; msg.AcknowledgeType = AcknowledgeTypes.FullReachQueue | AcknowledgeTypes.FullReceive; msg.AdministrationQueue = new MessageQueue(@".\private$\Ack"); if (SendTransactional) mq.Send(msg, MessageQueueTransactionType.Single); else mq.Send(msg); Additional Information: in the IIS logs on the destination machines I can see each message I send being recorded as a POST with a status code of 200. I am open to any suggestions.

    Read the article

  • Getting "Comment post not allowed (400)" when using Django Comments

    - by kfordham281
    I'm going through a Django book and I seem to be stuck. The code base used in the book is .96 and I'm using 1.0 for my Django install. The portion I'm stuck at is related to Django comments (django.contrib.comments). When I submit my comments I get "Comment post not allowed (400) Why: Missing content_type or object_pk field". I've found the Django documentation to be a bit lacking in this area and I'm hoping to get some help. The comment box is displayed just fine, it's when I submit the comment that I get the above error (or security warning as it truly appears). My call to the comment form: {% render_comment_form for bookmarks.sharedbookmark shared_bookmark.id %} My form.html code: {% if user.is_authenticated %} <form action="/comments/post/" method="post"> <p><label>Post a comment:</label><br /> <textarea name="comment" rows="10" cols="60"></textarea></p> <input type="hidden" name="options" value="{{ options }}" /> <input type="hidden" name="target" value="{{ target }}" /> <input type="hidden" name="gonzo" value="{{ hash }}" /> <input type="submit" name="post" value="submit comment" /> </form> {% else %} <p>Please <a href="/login/">log in</a> to post comments.</p> {% endif %} Any help would be much appreciated. My view as requested: def bookmark_page(request, bookmark_id): shared_bookmark = get_object_or_404( SharedBookmark, id=bookmark_id ) variables = RequestContext(request, { 'shared_bookmark': shared_bookmark }) return render_to_response('bookmark_page.html', variables)

    Read the article

  • Amazon API ItemSearch returns (400) Bad Request.

    - by BuzzBubba
    I'm using a simple example from Amazon documentation for ItemSearch and I get a strange error: "The remote server returned an unexpected response: (400) Bad Request." This is the code: public static void Main() { //Remember to create an instance of the amazon service, including you Access ID. AWSECommerceServicePortTypeClient service = new AWSECommerceServicePortTypeClient(new BasicHttpBinding(), new EndpointAddress( "http://webservices.amazon.com/onca/soap?Service=AWSECommerceService")); AWSECommerceServicePortTypeClient client = new AWSECommerceServicePortTypeClient( new BasicHttpBinding(), new EndpointAddress("http://webservices.amazon.com/onca/soap?Service=AWSECommerceService")); // prepare an ItemSearch request ItemSearchRequest request = new ItemSearchRequest(); request.SearchIndex = "Books"; request.Title = "Harry+Potter"; request.ResponseGroup = new string[] { "Small" }; ItemSearch itemSearch = new ItemSearch(); itemSearch.Request = new ItemSearchRequest[] { request }; itemSearch.AWSAccessKeyId = accessKeyId; // issue the ItemSearch request try { ItemSearchResponse response = client.ItemSearch(itemSearch); // write out the results foreach (var item in response.Items[0].Item) { Console.WriteLine(item.ItemAttributes.Title); } } catch(Exception e) { Console.ForegroundColor = ConsoleColor.Red; Console.WriteLine(e.Message); Console.ForegroundColor = ConsoleColor.White; Console.WriteLine("Press any key to quit..."); Clipboard.SetText(e.Message); } Console.ReadKey(); What is wrong?

    Read the article

  • WCF REST adding data using POST or PUT 400 Bad Request

    - by user55474
    HI How do i add data using wcf rest architecture. I dont want to use the channelfactory to call my method. Something similar to the webrequest and webresponse used for GET. Something similar to the ajax WebServiceProxy restInvoke Or do i always have to use the Webchannelfactory implementation I am getting a 400 BAD request by using the following Dim url As String = "http://localhost:4475/Service.svc/Entity/Add" Dim req As WebRequest = WebRequest.Create(url) req.Method = "POST" req.ContentType = "application/xml; charset=utf-8" req.Timeout = 30000 req.Headers.Add("SOAPAction", url) Dim xEle As XElement xEle = <Entity xmlns:i="http://www.w3.org/2001/XMLSchema-instance"> <Name>Entity1</Name> </Entity> Dim sXML As String = xEle .Value req.ContentLength = sXML.Length Dim sw As New System.IO.StreamWriter(req.GetRequestStream()) sw.Write(sXML) sw.Close() Dim res as HttpWebResponse = req.GetResponse() Sercice Contract is as follows <OperationContract()> _ <WebInvoke(Method:="PUT", UriTemplate:="Entity/Add")> _ Function AddEntity(ByVal e1 As Entity) DataContract is as follows <Serializable()> _ <DataContract()> _ Public Class Entity private m_Name as String <DataMember()> _ Public Property Name() As String Get Return m_Name End Get Set(ByVal value As String) m_Name = value End Set End Property End Class thanks

    Read the article

  • Java getInputStream 400 errors

    - by Bill Szerdy
    When I contact a web service using a Java HttpUrlConnection it just returns a 400 Bad Request (IOException). How do I get the XML information that the server is returning; it does not appear to be in the getErrorStream of the connection nor is it in any of the exception information. When I run the following PHP code against a web service: <?php $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "https://www.myclientaddress.com/here/" ); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1 ); curl_setopt($ch, CURLOPT_POST,1 ); curl_setopt($ch, CURLOPT_POSTFIELDS,"username=ted&password=scheckler&type=consumer&id=123456789&zip=12345"); $result=curl_exec ($ch); echo $result; ?> it returns the following: <?xml version="1.0" encoding="utf-8"?> <response> <status>failure</status> <errors> <error name="RES_ZIP">Zip code is not valid.</error> <error name="ZIP">Invalid zip code for residence address.</error> </errors> </response> so I know the information exists

    Read the article

  • Amazone API ItemSearch returns (400) Bad Request.

    - by BuzzBubba
    I'm using a simple example from Amazon documentation for ItemSearch and I get a strange error: "The remote server returned an unexpected response: (400) Bad Request." This is the code: public static void Main() { //Remember to create an instance of the amazon service, including you Access ID. AWSECommerceServicePortTypeClient service = new AWSECommerceServicePortTypeClient(new BasicHttpBinding(), new EndpointAddress( "http://webservices.amazon.com/onca/soap?Service=AWSECommerceService")); AWSECommerceServicePortTypeClient client = new AWSECommerceServicePortTypeClient( new BasicHttpBinding(), new EndpointAddress("http://webservices.amazon.com/onca/soap?Service=AWSECommerceService")); // prepare an ItemSearch request ItemSearchRequest request = new ItemSearchRequest(); request.SearchIndex = "Books"; request.Title = "Harry+Potter"; request.ResponseGroup = new string[] { "Small" }; ItemSearch itemSearch = new ItemSearch(); itemSearch.Request = new ItemSearchRequest[] { request }; itemSearch.AWSAccessKeyId = accessKeyId; // issue the ItemSearch request try { ItemSearchResponse response = client.ItemSearch(itemSearch); // write out the results foreach (var item in response.Items[0].Item) { Console.WriteLine(item.ItemAttributes.Title); } } catch(Exception e) { Console.ForegroundColor = ConsoleColor.Red; Console.WriteLine(e.Message); Console.ForegroundColor = ConsoleColor.White; Console.WriteLine("Press any key to quit..."); Clipboard.SetText(e.Message); } Console.ReadKey(); What is wrong?

    Read the article

  • Best MAILING LIST solution for a CONFERENCE and its 400 participants

    - by Ole Morten Amundsen
    Dear community, what would you recommend for mailling lists? The conference is non-profit, named Smidig2010 (=Agile2010 in norwegian), will have about 400-500 participants 16.-17.november. At the time of writing this, we have not opened for registration, but would like people to be able to participate, ask questions, get informed and get inspired. We've used a forum before, but forums don't seem to be a good fit for this. I would like to set up a mailinglist, It'll have to be KISS, for the users: enter your email (a input box at our site smidig2010.no) get a confirmation mail, click a link. start posting, reading through archives, answering others etc. I like the look and feel of googlegroups, but I don't like the signup/account creation overhead imposed on the user. I've heard you may combine googlegroups with mailman and stuff, but, yeah, I can't believe our own incompetence on this subject! Btw, we are mostly developers and the conference app is being written in ruby on rails. Being non-profit, we prefer free, but we take everything into consideration. Any suggestions?

    Read the article

  • HTTP 400 Bad Request error attempting to add web reference to WCF Service

    - by c152driver
    I have been trying to port a legacy WSE 3 web service to WCF. Since maintaining backwards compatibility with WSE 3 clients is the goal, I've followed the guidance in this article. After much trial and error, I can call the WCF service from my WSE 3 client. However, I am unable to add or update a web reference to this service from Visual Studio 2005 (with WSE 3 installed). The response is "The request failed with HTTP status 400: Bad Request". I get the same error trying to generate the proxy using the wsewsdl3 utility. I can add a Service Reference using VS 2008. Any solutions or troubleshooting suggestions? Here are the relevant sections from the config file for my WCF service. <system.serviceModel> <services> <service behaviorConfiguration="MyBehavior" name="MyService"> <endpoint address="" binding="customBinding" bindingConfiguration="wseBinding" contract="IMyService" /> <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" /> </service> </services> <bindings> <customBinding> <binding name="wseBinding"> <security authenticationMode="UserNameOverTransport" /> <mtomMessageEncoding messageVersion="Soap11WSAddressingAugust2004" /> <httpsTransport/> </binding> </customBinding> </bindings> <behaviors> <serviceBehaviors> <behavior name="MyBehavior"> <serviceMetadata httpGetEnabled="true" /> <serviceDebug includeExceptionDetailInFaults="true" /> <serviceCredentials> <userNameAuthentication userNamePasswordValidationMode="Custom" customUserNamePasswordValidatorType="MyCustomValidator" /> </serviceCredentials> <serviceAuthorization principalPermissionMode="UseAspNetRoles" roleProviderName="MyRoleProvider" /> </behavior> </serviceBehaviors> </behaviors> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" /> </system.serviceModel>

    Read the article

  • The remote server returned an error: (400) Bad Request

    - by pravakar
    Hi, I am getting the following errors: "The remote server returned an error: (400) Bad Request" "Requested time out" sometimes when connecting to a host using a web service. If the XML returned is 5 kb then it is working fine, but if the size is 450kb or above it is displaying the error. Below is my code as well as the config file that resides at the client system. We don't have access to the settings of the server. Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Dim fileName As String = Server.MapPath("capitaljobs2.xml") Dim client = New CapitalJobsService.DataServiceClient("WSHttpBinding_IDataService", "http://xyz/webservice.svc") Dim userAccount = New UserAccount() 'replace here Dim jobAdList = client.GetProviderJobs(userAccount) '## Needed only to create XML files - do not ucomment - will overwrite files 'if (jobAdList != null) ' SerialiseJobAds(fileName, jobAdList); '## Read new ads from Xml file Dim capitalJobsList = DeserialiseJobdAds(fileName) UpdateProviderJobsFromXml(client, userAccount, capitalJobsList) client.Close() End Sub Private Shared Function DeserialiseJobdAds(ByVal fileName As String) As CapitalJobsService.CapitalJobsList Dim capitalJobsList As CapitalJobsService.CapitalJobsList ' Deserialize the data and read it from the instance If File.Exists(fileName) Then Dim fs = New FileStream(fileName, FileMode.Open) Dim reader = XmlDictionaryReader.CreateTextReader(fs, New XmlDictionaryReaderQuotas()) Dim ser2 = New DataContractSerializer(GetType(CapitalJobsList)) capitalJobsList = DirectCast(ser2.ReadObject(reader, True), CapitalJobsList) reader.Close() fs.Close() Return capitalJobsList End If Return Nothing End Function And the config file <system.web> <httpRuntime maxRequestLength="524288" /> </system.web> <system.serviceModel> <bindings> <wsHttpBinding> <binding name="WSHttpBinding_IDataService" closeTimeout="00:10:00" openTimeout="00:10:00" receiveTimeout="00:10:00" sendTimeout="00:10:00" bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647" messageEncoding="Text" textEncoding="utf-8" useDefaultWebProxy="true" allowCookies="false"> <readerQuotas maxDepth="2000000" maxStringContentLength="2000000" maxArrayLength="2000000" maxBytesPerRead="2000000" maxNameTableCharCount="2000000" /> <reliableSession ordered="true" inactivityTimeout="00:10:00" enabled="false" /> <security mode="None"> <transport clientCredentialType="Windows" proxyCredentialType="None" realm=""/> <message clientCredentialType="Windows" negotiateServiceCredential="true" establishSecurityContext="true"/> </security> </binding> </wsHttpBinding> </bindings> <client> <endpoint address="http://xyz/DataService.svc" binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_IDataService" contract="CapitalJobsService.IDataService" name="WSHttpBinding_IDataService"> <identity> <dns value="localhost"/> </identity> </endpoint> </client> </system.serviceModel> I am using "Fiddler" to track the activities it is reading and terminating file like * FIDDLER: RawDisplay truncated at 16384 characters. Right-click to disable truncation. * But in config the number 16348 is not mentioned anywhere. Can you figure out if the error is on client or server side? The settings above are on the client side. Thanks in advance.

    Read the article

  • Detecting cause of RuntimeException: Unable to stop activity

    - by Pentium10
    I have a really weird error, and I don't know what is causing this. It happens when I leave the Activity. 05-16 12:26:20.360: ERROR/AndroidRuntime(11648): Uncaught handler: thread main exiting due to uncaught exception 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): java.lang.RuntimeException: Unable to stop activity {com.myapk/com.myapk.modules.viewPairing}: java.lang.NullPointerException 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3596) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:3674) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.access$2800(ActivityThread.java:126) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1965) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.os.Handler.dispatchMessage(Handler.java:99) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.os.Looper.loop(Looper.java:123) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.main(ActivityThread.java:4595) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at java.lang.reflect.Method.invokeNative(Native Method) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at java.lang.reflect.Method.invoke(Method.java:521) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at dalvik.system.NativeStart.main(Native Method) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): Caused by: java.lang.NullPointerException 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.Activity.performStop(Activity.java:3848) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3591) 05-16 12:26:20.400: ERROR/AndroidRuntime(11648): ... 11 more

    Read the article

  • The remote server returned an unexpected response: (400) Bad Request while streaming

    - by phenevo
    Hi, I have problem with streaming. When I send small file like 1kb txt everything is ok, but when I send larger file like 100 kb jpg or 2gb psd I get: The remote server returned an unexpected response: (400) Bad Request. I'm using windows 7, VS 2010 and .net 3.5 and WCF Service library I lost all my weekend on this and I still see this error :/ Please help me Client: var client = new WpfApplication1.ServiceReference1.Service1Client("WSHttpBinding_IService1"); client.GetString("test"); string filename = @"d:\test.jpg"; FileStream fs = new FileStream(filename, FileMode.Open); try { client.ProcessStreamFromClient(fs); } catch (Exception exception) { Console.WriteLine(exception); } app.config: <?xml version="1.0" encoding="utf-8" ?> <configuration> <system.serviceModel> <bindings> <basicHttpBinding> <binding name="StreamedHttp" closeTimeout="10:01:00" openTimeout="10:01:00" receiveTimeout="10:10:00" sendTimeout="10:01:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="65536000" maxBufferPoolSize="524288000" maxReceivedMessageSize="65536000" messageEncoding="Text" textEncoding="utf-8" transferMode="Streamed" useDefaultWebProxy="true"> <readerQuotas maxDepth="0" maxStringContentLength="0" maxArrayLength="0" maxBytesPerRead="0" maxNameTableCharCount="0" /> <security mode="None"> <transport clientCredentialType="None" proxyCredentialType="None" realm="" /> <message clientCredentialType="UserName" algorithmSuite="Default" /> </security> </binding> </basicHttpBinding> </bindings> <client> <endpoint address="http://localhost:8732/Design_Time_Addresses/WcfServiceLibrary2/Service1/" binding="basicHttpBinding" bindingConfiguration="StreamedHttp" contract="ServiceReference1.IService1" name="WSHttpBinding_IService1" /> </client> </system.serviceModel> </configuration> And Wcf ServiceLibrary: public void ProcessStreamFromClient(Stream str) { using (var outStream = new FileStream(@"e:\test.jpg", FileMode.Create)) { var buffer = new byte[4096]; int count; while ((count = str.Read(buffer, 0, buffer.Length)) > 0) { outStream.Write(buffer, 0, count); } } } App.config <?xml version="1.0" encoding="utf-8" ?> <configuration> <system.web> <compilation debug="true" /> </system.web> <!-- When deploying the service library project, the content of the config file must be added to the host's app.config file. System.Configuration does not support config files for libraries. --> <system.serviceModel> <bindings> <basicHttpBinding> <binding name="Binding1" hostNameComparisonMode="StrongWildcard" maxBufferSize="65536000" transferMode="Streamed" bypassProxyOnLocal="false" closeTimeout="10:01:00" openTimeout="10:01:00" receiveTimeout="10:10:00" sendTimeout="10:01:00" maxBufferPoolSize="524288000" maxReceivedMessageSize="65536000" messageEncoding="Text" textEncoding="utf-8" useDefaultWebProxy="true" allowCookies="false"> <security mode="None" /> </binding> </basicHttpBinding> </bindings> <client /> <services> <service name="WcfServiceLibrary2.Service1"> <host> <baseAddresses> <add baseAddress="http://localhost:8732/Design_Time_Addresses/WcfServiceLibrary2/Service1/" /> </baseAddresses> </host> <!-- Service Endpoints --> <!-- Unless fully qualified, address is relative to base address supplied above --> <endpoint address="" binding="basicHttpBinding" contract="WcfServiceLibrary2.IService1"> <!-- Upon deployment, the following identity element should be removed or replaced to reflect the identity under which the deployed service runs. If removed, WCF will infer an appropriate identity automatically. --> <identity> <dns value="localhost"/> </identity> </endpoint> <!-- Metadata Endpoints --> <!-- The Metadata Exchange endpoint is used by the service to describe itself to clients. --> <!-- This endpoint does not use a secure binding and should be secured or removed before deployment --> <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/> </service> </services> <behaviors> <serviceBehaviors> <behavior> <!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment --> <serviceMetadata httpGetEnabled="True"/> <!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information --> <dataContractSerializer maxItemsInObjectGraph="2147483647"/> <!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information --> <serviceDebug includeExceptionDetailInFaults="false" /> </behavior> </serviceBehaviors> </behaviors> </system.serviceModel> </configuration>

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >