Click here to Skip to main content
15,887,683 members
Everything / WCF

WCF

WCF

Great Reads

by Daniel Vaughan
Calcium provides much of what one needs to rapidly build a multifaceted and sophisticated modular application. Includes a host of modules and services, and an infrastructure that is ready to use in your next application.
by Roman Kiss
This article describes a design, implementation and usage of the Custom Routing Manager for managing messages via Routing Service built-in .Net 4 Technology.
by Roman Kiss
This article describes a design, implementation and tooling of model driven WorkflowServices logically centralized in the Repository and physically decentralized for their runtime projecting.
by Max Paulousky
This article presents the techniques and caveats of building Silverlight applications that can be notified about database state changes via polling duplex. WSHttp binding and CLR triggers are used to implement the solution as well.

Latest Articles

by NikStar
Using OutgoingMessageProperties and OperationContextScope to implement authorization by http header for WCF client that communicates with non WCF-based web services.
by ToughDev
How to fix PlatformNotSupportedException when running WCF apps
by lvmcastro
A tutorial showing how to use a smartcard API, a SharePoint extension and web services, to add a qualified electronic signature (QES) to a PDF file located in a SharePoint online library.

All Articles

Sort by Updated

WCF 

24 Dec 2023 by NikStar
Using OutgoingMessageProperties and OperationContextScope to implement authorization by http header for WCF client that communicates with non WCF-based web services.
20 Nov 2023 by Zijian
Live with WCF in the .NET Core Landscape
12 Nov 2023 by oronsultan
Hi! We have an important project in our company whose goal is to perform ON TRANSIT encryption between the client and the backend. The type of encryption we use is RSA 4K. The encryption on the client side is already done nicely. Also for...
5 Aug 2023 by aruaaa
I want to make my own instant messenger app in visual studio. Please help me from beginning and give samples, if any.Thanks in advance.
23 Jun 2023 by tanghuawei
The Exception:Could not load type 'Service.WorkFlowForm.Contract.RequestDto' from assembly 'Service.WorkFlowForm.Contract, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'.I was referenced the Service.WorkFlowForm.Contract.dll, the class RequestDto was new add,i can loadother...
4 May 2023 by jim lahey
Hello everyone,I'm facing a configuration issue concerning my WCF Streaming service. I've got a Windows service that self-hosts 3 WCF Services, one of which handles the uploading and downloading of binary content using Streams. The documentation around states that you have to set...
4 May 2023 by Member 15996065
I found a simple solution to this problem If one configures the variable "maxReceivedMessageSize" in the app.config, it didn't work for me What I did was do it in the code, as follows: ServiceX.Service1Client ServMyService = new...
11 Apr 2023 by Member 10426394
Hi everybody… I would like to migrate an old and quite complex WCF client-server application that was written in VB.net with Visual Studio. WCF is not supported since Framwork 4.8 and will be deprecated soon, that's why I want to replace this...
11 Apr 2023 by Dave Kreskowiak
Well, your best choices are gRPC or CoreWCF, for .NET Core. Any code samples for either of these are going to be in C#. You'll have to convert the code to VB.NET yourself. The two languages are not as different as they seem on the surface.
15 Dec 2022 by Nicholas Marty
I've got a few problems configuring an ASP.NET Webapplication which hosts a WCF Service. And I've been searching quite a while now. There are quite a lot of results to be honest, and I'm not an expert with WCF. Mostly the solutions are either for the wsHttpBinding (which i don't use) or showing...
15 Dec 2022 by rogerperkins
Thank you, I've been trying to figure this out all day. Your comment about require ssl clued me in. Yes, I need both http and https bindings in iis for webHttpBinding, in my case, to work, so I set those up as normal port 80 and port 443 web...
13 Oct 2022 by Toby Mason-Barney
Hi,I am currently looking for a new developer position and have come to realize that a lot of employers ask for coding/programming examples. Unfortunately all the professional work I have done is covered by strict NDA and can not be shared, and the work I did during my degree is...well pants...
2 Oct 2022 by sagar wasule
Hi,I have an requirement where I have to consume WCF(svc) services in my application dynamically, i.e. I will have a textbox in my application where the user enters the URL of the service and hits a button which will make my service consumable in my application. I will list out the methods...
3 Aug 2022 by lvmcastro
A tutorial showing how to use a smartcard API, a SharePoint extension and web services, to add a qualified electronic signature (QES) to a PDF file located in a SharePoint online library.
28 Feb 2022 by Utku Ozan ÇANKAYA
How to add logging to WCF services
28 Feb 2022 by Utku Ozan ÇANKAYA
How to add authentication and authorization to WCF services
28 Feb 2022 by Utku Ozan ÇANKAYA
How to add validation to WCF service requests
28 Feb 2022 by Utku Ozan ÇANKAYA
Basics of improving WCF service quality
28 Jan 2022 by #realJSOP
Radio buttons don't have "values". They have a checked status. The way I'd do it is to associated an integer value with each radio button, and pass that "value" to the WCF method. The easiest way to implement this paradigm is to assign the Tag...
28 Jan 2022 by DivyaHal
I have created two radiobuttons using WPF, and one normal button. The processing of files and reading everything done with WCF. If I choose radiobutton_1 and click the run button, it will display different files. And if I click radiobutton_2 and...
2 Jan 2022 by Ubaldo Formichetti
Hi, I need to build a wcf service, which uses a custom response, in jsonp format, I should get a response like this example: calling this example method:...
2 Jan 2022 by Ubaldo Formichetti
HI, somehow I managed to solve it, I don't know if this is the best way, however I solved my problem, like this: The service: I removed the interface file, added the MyType class, which has a settable object "d" property, which I then return as...
23 Nov 2021 by ddas-edEn
We have a WCF web service hosted on Windows 2008 SP2/IIS 7 accessing an Oracle database. Usually data access works fine but during load testing, it often times out and logs and exception saying:Error occurred when processing XXXXXXXX Web ServiceOracle.DataAccess.Client.OracleException...
23 Nov 2021 by manikjeyam
cmd.Parameters["P_retvalue"].D...
19 Nov 2021 by jgauffin
codeRR is an open source error handling service. It includes the context information that you forgot to include when you logged/reported the exception.
16 Nov 2021 by saxenaabhi6
I got a website working on http and https bothbut mywebsite.com/xyz.svc only works with http not with https.solution tried:added binding below: ...
18 Jul 2021 by Sreejith Kizhakkedath
Add the below section in Web.config file of your WCF service.
18 Jul 2021 by Member 13379347
Hello Techies, I am facing this error from last many days and I have done almost everything but this doesn't wants to go. So finally putting this here to seek a solution So I have a ASP.NET website and a WCF service hosted on server. Both are...
1 Jun 2021 by Elite Labs
Application: WindowsService1.exe Framework Version: v4.0.30319 Description: The process was terminated due to an unhandled exception. Exception Info: System.InvalidOperationException at...
1 Jun 2021 by Richard Deeming
A Windows Service is a non-interactive process which runs in the background. There could be multiple users logged in to the computer, or there might not be any users logged in to the computer. Therefore, a service cannot show any user interface...
4 May 2021 by Member 13366692
I have created a web service to connect my android app to my vb.net site but its not working and I don't know why , there is no error? C My site in smarterasp.net free hosting this is my java code ? public class MainActivity extends AppCompatActivity { ArrayList>...
4 May 2021 by Member 13366692
I have created a WCF services to connect my android app with my SQL database on online site , first of all I can test the service on my local machine but on the server I can't it says : Test The test form is only available for requests from the local machine. I do not know if this has an...
8 Feb 2021 by Gnanavel ncore
1.Hi All,while I change or modify something in data access layer, I am getting below mentioned error.1. Unable to copy file "C:\bin\Debug\ajaxservice.Data.dll" to "bin\Debug\ajaxservice.Data.dll". The process cannot access the file 'bin\Debug\ajaxservice.Data.dll' because it is being...
8 Feb 2021 by DaaJason
I know this is an old post, but I keep getting a similar problem, google it, and then remember what I keep doing. For the multiple posts by javascript, here is what I sometimes accidently do and get the same behavior. My WCF Method is defined...
30 Dec 2020 by I DoesCode
I'm creating an event-management system. In this system I have a WCF service which loads the events. I have a layered architecture with a repository and service layer. The data is published to an Azure web service app. The data is consumed in a...
18 Nov 2020 by Lokesh Kondapalli
hello....am facing little bit problem over here... due to buffer size i changed my web.config like this.. ...
2 Nov 2020 by Member 10785772
Hello, I'm trying to learn how to create a json REST webservice and starting off with a simple example ... but can't get it to function. This is what I get when attempting to call it with a cUrl ... curl -X GET -v...
31 Oct 2020 by Member 14980454
As per my understating lets consider you have hosted one WCF service and you want to publish two method one is for your organization which will contains your companies details and other is for your client , so if you use abstract class you can...
31 Oct 2020 by Member 11072126
Hi All, I cam up with a small doubt while working on WCF. I am looking for this answer for few days over internet but couldn't find any well-explained article on this topic. Question 1: Why we use interface in WCF? We could have written the operation contracts, data contracts, etc., without...
22 Oct 2020 by Unal Avci
I have the same problem. If you did, how did you do it? Thanks.
29 Sep 2020 by Bippy_B
What sort of error are you getting? Without knowing what the error is it is somewhat hard to interpret. Is the service even starting? If the service is starting I would recommend seeing if the "help" section will display. If the service...
29 Sep 2020 by cutie1
I have written a WCF service to return a JSON response.However I coulnot get it ?Here is my code:IService.cs: [OperationContract] [WebInvoke(UriTemplate = "GetAppointments/?companyId={companyId}&appointmentDate={appointmentDate}", Method = "GET", RequestFormat =...
17 Sep 2020 by Member 14724056
I have developed WCF windows service using net tcp binding. Its working fine when wcf client and wcf service both are in domain (in two different system) Getting error when both system are in work group not in domain please suggest what...
17 Sep 2020 by Sandeep Mewara
Quote: Local socket timeout was '00:29:59.9687496' You are hitting timeout of 30 min. Don't think an operation whould be that long and thus mostly configuration based issue where a client not able to talk cross domain. Look at these similar...
1 Sep 2020 by Judah91
I need to implement a WCF request with WS-Security. The header must to have this tags (Signature, UsernameToken and Timestamp) as shown below:
25 Aug 2020 by Akram Ahmed
Hello Team, We have a WCF service that is hosted at the production server as well as my local machine, Previously I was able to communicate my local WCF service through our Web application(MVC) over the net.tcp as well as the http, but after the...
25 Aug 2020 by Member 12500178
Hi Akram. Did you solve this issue? Same issue happened to me but I unsinstall this KB and still not working.
31 Jul 2020 by Chinmoy Mohanty
How to upload/download a file using WCF REST service in .NET 3.5
31 Jul 2020 by Chinmoy Mohanty
How to create and consume a RESTful service using WCF and JavaScript
31 Jul 2020 by Abbathsin
I have been using Net Remoting for so long that I'm trying migrate to WCF because I need to now pass all this data to a web through json. The reason is that the libraries I use are licensed and these are for machine communication (Interop and...
31 Jul 2020 by Jin Vincent Necesario
Hi, In my opinion, you are on the right track. You really need to upgrade or migrate to WCF because it also supports REST. However, if you can migrate directly to ASP.NET Web API that would be great. Now for the migration steps, here are...
31 Jul 2020 by Chinmoy Mohanty
How to do operation contract overloading in WCF
12 Jul 2020 by triyul22
I have WCF service to store and retrieve messages (in/from a database). I'm calling it from ASP.NET. When I run my app I face with following problem: The remote server returned an error: (400) Bad Request. I don't actually understand how to...
12 Jul 2020 by Garth J Lancaster
Given your content type is JSON, should not this DataContractSerializer ser = new DataContractSerializer(typeof(Message)); be this DataContractJsonSerializer ser = new DataContractJsonSerializer(typeof(Message)); It's the only thing that is...
11 Jul 2020 by syedkhaleel
Hi All,I am trying to pass a complex object to WCF service through a Client Application.When i debug the code, I see object is coming as null.I tried the following code.Interface method[OperationContract] [WebInvoke(Method = "POST", ResponseFormat =...
11 Jul 2020 by sreeharijakkala
You have BodyStyle as WrappedRequest,so you need to do- Either remove Hide Copy Code BodyStyle = WebMessageBodyStyle.WrappedRequest or pass your object like Hide Copy Code { "comp": { "ComplainType": "1", "ComplainBody":...
3 Jul 2020 by paniraj n
Hello I am getting below error when I am trying to call WCF service from ASP.Net Core, this is happening only when both wcf service and API deployed on IIS 10. ...
3 Jul 2020 by Richard Deeming
Either you're trying to connect on the wrong port, or there is a firewall blocking the connection. If you're trying to call the service using the public domain name, then the traffic is probably being sent via your router. Try using the...
13 Jun 2020 by Member 13187373
Hi All, I am using Windows form application. I have total 688 unit tests written in my project. When I am running these unit tests on my local development environment then these all are passing successfully but when I am running these unit tests...
4 Jun 2020 by SREEKAN2
Hi I am having an WCF sync Service hosting on IIS7 on my server, I can access the URL in browser, Actually i built the WCF service and later on i added a wcf service website to my solution by adding my wcf service reference. and in the service.svc file i mentioned the particular service. the...
4 May 2020 by Zijian
Generate strongly typed client API in C# for ASP.NET Web API and .NET Core Web API supporting desktop, Universal Windows, Android and iOS
17 Apr 2020 by MadMyche
Have you checked the BasicHttpBinding.MaxReceivedMessageSize Property? By default is it set to 64MBProperty Value Int64: The maximum size, in bytes, for a message that is processed by the binding. The default value is 65,536 byt This can be set...
17 Apr 2020 by kedar001
while uploading a 98 mb file to wcf service i'm getting bellow error Quote: The remote server returned an unexpected response: (413) Request Entity Too Large. web.config -
27 Feb 2020 by OriginalGriff
The error is a HTTP error message: 404, which menas "page not found" HTTP 404 - Wikipedia[^] What it means is that whatever is talking to your WCF service can see the server, but not the service at all. At a guess, it's looking at the wrong...
27 Feb 2020 by Member 14738666
Server Error in '/' Application. The resource cannot be found. Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the...
26 Feb 2020 by phil.o
girishmeena wrote: Service: Calls - Number of calls to this service. The counter of total number of calls issued to the service. Every new call increments this counter by one. girishmeena wrote: Service: Calls Per Second - Number of calls to...
26 Feb 2020 by girishmeena
Hi All, What is the relation between WCF performance counter Calls, Calls duration, Calls Outstanding, Calls Per Second? WCF Performance Counters - WCF | Microsoft Docs[^] mentions Service: Calls - Number of calls to this service. Does it mean...
10 Feb 2020 by Member 2123760
It happens on any 2.0 and also in .net framework 4.7.2 & 4.5. I think issue is something else, may be below. When I tried to browse service url, it went through ssl communication step and then asking for username password. It seems like it needs...
10 Feb 2020 by Member 2123760
in .net core we are trying to add wcf service reference and show us TLS SSL issue. Would it be possible that if the end point is requiring credentials? from connected service > chose wcf to add > add the URI (ends with .svc) > keeping all defaults in next pages, clicking on finish shows below...
30 Jan 2020 by Richard MacCutchan
See What Is Windows Communication Foundation - WCF | Microsoft Docs[^]
30 Jan 2020 by mmbguide
Hello Which one of bellow projects shall be WCF type in my solution in service-oriented application? ProjectName => Project Type => Description Entities => WCF => Structure of my database tables Contracts => WCF => Interface of all methods and functions Data => Class Library => data access...
21 Jan 2020 by Member 11969195
I am runnig this application on windows 10. What I have tried: i Just created a simple "Empty ASP.Net web application" and added a web services named as "HelloWebService.asmx" within this file created a single method called as "GetMessage" with single parameter as follows: public class...
15 Jan 2020 by Dalerico
I have a wcf rest service, which I created a MemoryStream for one of my operation contracts that has an object, which encapsulates many properties. This is a GET HTTP request for data to the client (Android music app). I've wrote some code to take my service side MemoryStream into the java...
15 Jan 2020 by Dalerico
Partial code (c#) from the server side: Prepares a Data object for transmission over the wire byte[] byteArray = new byte[4000]; // Convert the data Object (generic list) to be serialized and return a JSON string. var json1 = new...
15 Jan 2020 by phil.o
A MemoryStream is just a stream, i.e. a list of byte values. You have to send the byte array over the wire (either directly by writing from memory stream to a network stream, or by encoding it, for example in Base64, and send the encoded value instead). In the receiving java application, you...
10 Jan 2020 by Kris Lantz
According to the documentation here: Stream.ReadByte Method (System.IO) | Microsoft Docs[^], the ReadByte() Method is going to read the first byte of the stream, and advance by one, meaning using (var reader = new StreamReader(data)) will be processed from data[1], instead of data[0].
10 Jan 2020 by Member 14601214
I have a wcf rest service with Stream as input parameter: [OperationContract] [WebInvoke(Method = "POST", ResponseFormat = WebMessageFormat.Json, BodyStyle = WebMessageBodyStyle.WrappedRequest)] void ImportStream(Stream data); And this is my text as input in POSTMAN: ...
7 Jan 2020 by Member 4581741
Hi, I have created a service where there would be a private cert on the server where i am hosting the service and the client will have public key of it. And the client would have a different private key where they will encrypt the message which they send to the endpoint i create and i have the...
7 Jan 2020 by phil.o
Use https. You just have to create a valid certificate for the server, once done you will have nothing else to worry about.
3 Dec 2019 by sheik SHA
I have a WCF service, every 30 seconds it pushes the status to connected clients my service code here: private void StartStatusPushing(int callBackInterval) { Task.Factory.StartNew( () => { while (true) ...
3 Dec 2019 by sheik SHA
Thank you i found it :) in code i set a ClosedTimeout is 10 minutes, so its not publishing the status update to next 10 minutes, so i set it to 10 seconds its working as expected Thank you so much for your support.
2 Dec 2019 by RamiroX
I think your WCF went to an invalid state after client closed. That means you cannot use that previous WCF proxy anymore.
1 Dec 2019 by Aishwarya Hegde
This should be possible however I have searched extensively and have found no answers to this, using WCF ISerializable interface concept. Hopefully the experts can help. Any documentation I have read only refers to info.AddValue(...) concept similar to the ones in...
1 Dec 2019 by Maciej Los
Seems, you don't understand what Serialization[^] is... An object to serialize/deserialize have to have at least one public member. But Class2 has got none public member! See: ISerializable Interface (System.Runtime.Serialization) | Microsoft Docs[^] void Main() { Class2 t = new Class2();...
21 Nov 2019 by Jeremy Likness
Build data-driven .NET applications with seamless client-server communication using fluent C# LINQ over OData (like GraphQL but without the JSON).
19 Nov 2019 by Tshumore
I have a WCF Rest service that is making a call to a remote server. The service sends some of the parameters as Query parameters (dynamic) and some as static. The static parameters are already configured in web.config as appkeysettings :
13 Nov 2019 by RickZeeland
See example here: https://www.aspsnippets.com/Articles/Call-Consume-REST-WCF-Service-SVC-in-Console-Application-using-C-and-VBNet.aspx[^]
13 Nov 2019 by Swati_g1985
Hi All, I am new to WCF. I need to consume one Rest WCF service in the Console Application. The WCF Service is already running on my computer e.g. http://localhost:1004/REService. I need to access REService.IREService.GetReports method. Kindly help. Thanks in advance. What I have tried: I...
12 Nov 2019 by Swati_g1985
Hello All, I have one existing running net tcp WCF service (hosted as windows services). I need to consume it using Console Application. Can I do it without adding Service Reference? Our requirement is not to use it as service reference. Thanks in advance. What I have tried: I tried adding ...
18 Oct 2019 by Magic Wonder
Hi, I am having a WCF REST Service. I am getting above mentioned error when my data.length is exceeding bytes more than 64931 approximately. Find my web.config as below