Search Results

Search found 9370 results on 375 pages for 'wcf rest contrib'.

Page 48/375 | < Previous Page | 44 45 46 47 48 49 50 51 52 53 54 55  | Next Page >

  • Mandatory Parameters in Request object (WCF)

    - by Martin Moser
    lHi, I'm currently writing a WCF service. One of those methods get's a request object and returns a response object. In the request there are a couple of value-type members. Is there a way to define members are mandatory in the declarative way? I'm in an early stage of development and I don't want to start with versioning now. In addition I don't want to have method sig with 25 parameters, therefore I created the request object. The problem I have is that due to the value-types, I can never be sure if the consumer of the service intended to have the default value in there, or it was just by lazyness. On consumer side you don't easily detect that you probably missed that property. So I would like to have something that forces the caller of the service to provide an value, and if not he ideally get's a compile-time error. any ideas? tia, Martin

    Read the article

  • LINQ insert to database by WCF Service from Silverlight app

    - by Rafal
    Hi I have a problem during insert to database by LINQ command in WCF Service from Silverlight application. Receiving data works fine - select works in LINQ and shows data from database(sql server 2008). When i try to insert data, the Error ocures: System.Net.WebException: The remote server returned an error: NotFound. ---> System.Net.WebException: The remote server returned an error: NotFound. at System.Net.Browser.BrowserHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult) at System.Net.Browser.BrowserHttpWebRequest.<>c__DisplayClass5.<EndGetResponse>b__4(Object sendState) at System.Net.Browser.AsyncHelper.<>c__DisplayClass2.<BeginOnUI>b__0(Object sendState) --- End of inner exception stack trace --- at System.Net.Browser.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state) at System.Net.Browser.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result)} It looks the same, when i had a wrong ClientConfig/Web.config file. Please Help...I need to insert some data:)

    Read the article

  • Good tool to test WCF service (not SOAP/HTTP webservice)

    - by Kangkan
    I recently found SOAPUI and discovered that it is just a great tool for testing any SOAP/HTTP service. Conventionally, we have been developing our own driver to test our services (WCF based netTCP binding) so far. But with SOAPUI experience, I am really looking for some such tool that can be used with such ease with built-in facilities for load testing, functional testing etc. The other thought in my mind is that for services that I wish to deploy with netTCP can be first tested using a HTTP binding using SOAPUI. Once found suitable, the binding can be changed for the intended one. I shall like the views from all the experts here. Thanks.

    Read the article

  • WCF service hosted in IIS 5.0 - http get methods not invoked through the browser

    - by Dmitry
    I have service hosted in IIS5.0 and configured such way : ** <behaviors> <endpointBehaviors> <behavior name="GalleriesBehavior"> <webHttp/> </behavior> ** When I make request to http://localhost/sandboxWidget/Galleries.svc?Test ,the message I get is : "Metadata publishing for this service is currently disabled." and instructions how to expose meta data exchange...Tried this but doesn't help.. I can write any function name ,even not existing (http://localhost/sandboxWidget/Galleries.svc?blabla) ,but the message is same .... I'm new to Wcf ,but what looks me strange is that ,the same application was working in my job environment ,but not on my home PC .... I have same VS2008,NET3.5 with service pack 1

    Read the article

  • How to get a reference to IDuplexChannel, IDuplexSessionChannel or IOutputChannel in Wcf

    - by wizlb
    I have a duplex Wcf service and I'd like to get a reference to IDuplexChannel, IDuplexSessionChannel or IOutputChannel so that I can use the non-blocking BeginSend method. On my server, inside of the handler for the initiating method I have the following (I have tried every interface that I listed in place of IOutputChannel. None of them seem to exist.) _clientCb = OperationContext.Current.GetCallbackChannel<IDxClientCb>(); _channel = OperationContext.Current.Channel; _duplexChannel = _channel as IOutputChannel; Debug.Print("Service IOutputChannel null: {0}", _duplexChannel == null); Similarly, in the client I have tried to cast the return value of DuplexChannelFactory.CreateChannel() to any of these interfaces and I always get back a null. How do I get a reference to one of these?

    Read the article

  • Interface(s) inheriting other interface(s) in WCF services.

    - by avance70
    In my solution there's a few WCF services, each of them implementing it's own callback interface. Let's say they are called: Subscribe1, with ISubscribe1 and ICallback1, etc. It happens there are a few methods shared among ICallbacks, so I made a following interface: interface ICallback { [OperationContract] CommonlyUsedMethod(); } and i inherited it in all: ICallback1 : ICallback, ICallback2 : ICallback, etc. And deleted the CommonlyUsedMethod() from all callback interfaces. Now, on the service-side code, everything compiles fine and services can start working as usual. But, when I updated the service references for the client, CommonlyUsedMethod() dissapeared from the reference.cs file (the ISubscribeCallback part), and could no longer be used to send data to back to the client.

    Read the article

  • Simple WCF question.

    - by bearrito
    So I am learning WCF and I have run across an issue that I believe has to do with Instance Control/State but I am not sure. Workflow is as follows, Basic client/server paradigm. The client calls a Method RetrieveBusinessObjects(criteria) and the server calls the datalayer and then puts them in an IList on the server side. It does not return this list to the calling Client. The client would then call a method say DisplayBusinessObjects() which would retrieve the IList from the Server, serialize them, bring them across the wire and display them. If i try this using the WCFTestClient it works. If I run it from an actual client then I get back an BusinessObject[] of size 0. Which to me indicates I had no objects to return. Is that a state mgmt issue or am I missing something?

    Read the article

  • Using WCF HttpBindings on a LAN

    - by dcw
    We have a WCF-based client server that operates over a LAN. We've been getting along ok by using the NetTcpBinding, chosen because we couldn't get either HttpBinding to work between hosts. (Within a single host works fine, but is not useful for the production environment.) We're now back at the point where we want to explore using either BasicHttpBinding or WsHttpBinding, but we simply can't see the server from the client: even putting in the path to the endpoint into IE fails to see the server. Is there something simple we've overlooked? We're not specifying any security settings (or anything else, for that matter). Should we be doing so (e.g. explicitly setting security settings to None)?

    Read the article

  • Updating/Inserting multiple rows using jQuery and OData (WCF Data Services)

    - by Pieter
    I have three tables, Template, Fields and TemplateFields. TemplateFields holds the selected fields for each template. I need to update TemplateFields when the user is finished selecting the fields. The only way I can see to do this is by deleting all the TemplateFields for that Template and then add them one by one in separate requests. This is really bad because there is not transaction to fall back onto and there will also be MANY requests. Is there a way of adding multiple 'objects' at once using WCF Data Services? I can then use an Interceptor to update the database.

    Read the article

  • Modal dialog blocks wcf callback

    - by Bjarne
    I am working on an application that relies strongly on a wcf request/callback pattern. That is, it uses a service which exposes a number of methods, and for each method there is a callback on which the result is returned. In the client, I wish to open a modal dialog, make a request on the server and then wait for the result on the callback. But I never get a callback since the UI thread is blocked by the modal dialog. Has anyone worked with a similar pattern? I would hate to have more threads in the client, and I also don't like the idea of 'simulating' a modal dialog.

    Read the article

  • WCF service reference stopped generating code for one project

    - by Mike Pateras
    I have references to two different WCF services in a project. I updated the reference for one of the services, and now no code is generated for it. The references.cs file just has the "this is genrated code" comment at the top. Updating that same service in other projects and updating the other service both work fine. It's only that one service reference in this one project that's causing the problem, and I'm getting no information from Visual Studio (it just says it failed to generate code and I should look at the other errors, which provide no information). If I uncheck the "reuse types in referenced assemblies", code is generated, but I don't want to have this one project be different from the others. I'd like to solve the problem. Re-checking the reuse type option produces an empty references.cs file, again. The collection type doesn't seem to matter, either. How can I diagnose and solve this problem?

    Read the article

  • EntityFramework WCF issue

    - by Andres Blanco
    Right now i'm doing some tests involving entityFramework and WCF. As I understand, the EntityObjects generated are DataContracts and so, they can be serialized to the client. In my example I have a "Country" entity wich has 1 "Currency" as a property, when I get a Country and try to send it to the client, it throws an exception saying the data cant be written. But, the thing is, if I Get a Currency (which has a collection of Countries) and dont load its countries, it does work. The client gets all the entities. So, as a summary: - I have an entity with another entity as a property and cant be serialized. - I have another entity with an empty list of properties and it is successfully serialized. Any ideas on how to make it work?

    Read the article

  • Windows installer custome action call WCF to get value from remote failed.(NoEndpoint found exeption

    - by malik
    I am using windows installer to deploy my application. And i have add a custom action to access a WCF service from remote server. While installing application i found endpoind not found exception. ServiceReference.testContractsClient client; var wsBinding = new WSHttpBinding(SecurityMode.None, false); //End point i take from user input EndpointAddress endpointAddress = new EndpointAddress(ctlWebServiceUrl.Text); wsBinding.MaxReceivedMessageSize = int.MaxValue; client = new ServiceReference.testContractsClient(wsBinding, endpointAddress); client.test(); //method call If i connect to LAN (network) it works, same installer work on all machine. Windows XP Professional on only one PC have issue. If anybody can help..

    Read the article

  • WCF DataContract GetCustomDataToExport

    - by JeffN825
    I'm trying to get the default behavior for a client referencing my WCF WSDL to set IsReference to true on the imported DataContracts. It looks like I should be able to use an IDataContractSurrogate with GetCustomDataToExport to accomplish this...which specifcally means adding the following to the generated ComplexType in the xsd associated with the WSDL: <xs:attribute ref="ser:Id" /> <xs:attribute ref="ser:Ref" /> There is, of course no usable documentation I can find from MS about how to use this method. The MSDN page says it should return an object...but does not indicate at all what type of object this should be....how useless... Before I go reflector'ing for this, does anyone out there know how to use this method? Thanks.

    Read the article

  • Read from output file in installed WCF service

    - by fishiefishie
    I included a text file as output in a WCF set up project. The text file is correctly located in the same folder with the dll, exe, and config file after the project is installed (C:\Program Files\KLTesting\KLTestApp). However when the program tries to read it, it looks under "C:\Windows\system32", what's the correct way to find & read it? I have string a = Directory.GetCurrentDirectory(); a += "/R0303.txt"; string content = File.ReadAllText(a); Thanks.

    Read the article

  • Is there an example of checking on if a WCF Service is online?

    - by apolfj
    I will have a client application using a proxy to a WCF Service. This client will be a windows form application doing basicHttpBinding to N number of endpoints at an address. The problem I want to resolve is that when any windows form application going across the internet to get my web server that must have my web server online will need to know that this particular WCF Service is online. I need an example of how this client on a background thread will be able to do a polling of just "WCF Service.., Are You There?" This way our client application can notify clients before they invest a lot of time in building up work client-side to only be frustrated with the WCF Service being offline. Again I am looking for a simple way to check for WCF Service "Are You There?"

    Read the article

  • Visual Studio WCF Application now asking to manually attach to process

    - by JL
    I have a console app that is calling a WCF app hosted in IIS. Up until now everything has been fine and I am able to debug the app - step through it without any problems... Until I added my dev pc to a domain.... now every time I get step into the code hosted in IIS, a popup comes up asking if I would like to attach to this process... I can then continue debugging... again not a huge train smash - however... now it randomly just jumps to the end of the process (almost like some kind of timeout) and I am not able to reliably step and debug the IIS hosted code.... Any ideas? All the projects are in the same solution, and all running on the local dev pc... Using Visual Studio 2008, dev PC is Win 7

    Read the article

  • How to programmatically generate WSDL from WCF service (Integration Testing)

    - by David Christiansen
    Hi All, I am looking to write some integration tests to compare the WSDL generated by WCF services against previous (and published) versions. This is to ensure the service contracts don't differ from time of release. I would like my tests to be self contained and not rely on any external resources such as hosting on IIS. I am thinking that I could recreate my IIS hosting environment within the test with something like... using (ServiceHost host = new ServiceHost(typeof(NSTest.HelloNS), new Uri("http://localhost:8000/Omega"))) { host.AddServiceEndpoint(typeof(NSTest.IMy_NS), new BasicHttpBinding(), "Primary"); ServiceMetadataBehavior behavior = new ServiceMetadataBehavior(); behavior.HttpGetEnabled = true; host.Description.Behaviors.Add(behavior); host.AddServiceEndpoint(typeof(IMetadataExchange), MetadataExchangeBindings.CreateMexHttpBinding(), "mex"); host.Open(); } Does anyone else have any better ideas?

    Read the article

  • WCF: Callback is not asynchronous

    - by Aquarius
    Hi, I'm trying to program a client server based on the callback infrastructure provided by WCF but it isn't working asynchronously. My client connects to the server calling a login method, where I save the clients callback channel by doing MyCallback callback = OperationContext.Current.GetCallbackChannel() After that the server does some processing and uses the callback object to communicate with the client. All this works, the problem resides on the fact that even though I've set the method in the OperationContract as IsOneWay=true, the server still hangs when doing the call to the client. I've tested this by launching the server for debug in the visual studio, detaching it, launching the client, calling the above mentioned login method, putting a break point in the implemented callback method of the client, and making the server send a response to the client. The server stops doing what it's supposed to do, waiting for the response of the client. Any help is appreciated.

    Read the article

  • Replacing TCP/IP pipe with WCF

    - by msarchet
    So currently my company is using a TCP/IP connection to talk between server and client programs, right now we are building this connection using System.RunTime.Remoting, which is clunky and not that reliable. It was built about 5 years ago and the model keeps getting reused and it's starting to propagate some issues, ports used, refused connections, etc. I'm trying to find some resources on how to change this over to WCF but I'm not really sure what I am looking for or what I should be searching. If you want some more information on what were actually doing with it I can go into some detail, but I'll need to pull up the code and make sure I explain it completely. thanks!

    Read the article

  • Dynamically setting WCF endpoint

    - by Matt
    Ive just started using WCF with silverlight and its working fine. But one thing that is bugging me is the address of the .svc. Why is it statically set in the .config? Would it be possible to set it when creating an instance of the proxy class? And if so, is there a way to set it to the current address? Our software will be deployed on many different domain and we cant change the config every time. The svc will always be in the same domain as the silverlight page. Thanks.

    Read the article

  • WCF SERVICE gives us faulted response

    - by malik
    My service is hosted on IIS7, windows 2008 server with sql server2008 express. I am getting following error when the process takes more than 2 minutes i got this response, i m unable to find out either it is due to sql server time out or wcf time out. my sql server process is also took long. An error occurred while receiving the HTTP response to http://REMOTE/SynchronizationService_test/SyncService.svc. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.

    Read the article

  • WCF returning custom types

    - by Gena Verdel
    Hi. I'm a newbie to WCF, trying to perform relatively simple task. I'm trying to return list of objects read from the database but cannot overcome some really annoying exceptions. The question is very simple? What's wrong with the picture? [ServiceContract] public interface IDBService { [OperationContract] string Ping(string name); [OperationContract] InitBDResult InitBD(); } public InitBDResult InitBD() { _dc = new CentralDC(); InitBDResult result = new InitBDResult(); result.ord = _dc.Orders.First(); return result; } [DataContract] public class InitBDResult { //[DataMember] //public List<Order> Orders { get; set; } [DataMember] public Order ord { get; set; } }

    Read the article

  • Why my WCF Service returns xml serialized objects?

    - by user294554
    Hi, I'm new here and I hope anyonte can help me. I have WCF Service and Windows Forms working with this client written in VB.NET. The Service class started to return xml serialized objects, but all my classes on Service side are DataContract-s and the service class is DataContractFormat. I googled everywhere about serializations and I couldn't find reason why it started to do that. I checked my classes and service, app.config file, but I couldn't find anything. I checked Reference.vb class, and it's System.Xml.Serialization.XmlElementAttribute everywhere. The question may seem dummy, but I really don't know what to do. I just want to know what can cause the service to act like that. Thank you.

    Read the article

  • WCF host address question

    - by Estelle
    when I setup the wcf service on a web server, I set the end point address as <endpoint address="http://www.mydomin.com/clientname/happy.svc" binding="basicHttpBinding" name="happysvcbasic" contract="happysvc.Ihappysvc"> </endpoint> but when type in above address on a browser, I get a different host name, which is the internal server name, such as, To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax: svcutil.exe http://internalservername.domain/clientname/happy.svc?wsdl I tried to add the host/baseaddress tag, but make no difference, what I missed? thanks for help.

    Read the article

< Previous Page | 44 45 46 47 48 49 50 51 52 53 54 55  | Next Page >