For those new to message boards please try to follow a few simple rules when posting your question.
Choose the correct forum for your message. Posting a VB.NET question in the C++ forum will end in tears.
Be specific! Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.
Keep the subject line brief, but descriptive. eg "File Serialization problem"
Keep the question as brief as possible. If you have to include code, include the smallest snippet of code you can.
Be careful when including code that you haven't made a typo. Typing mistakes can become the focal point instead of the actual question you asked.
Do not remove or empty a message if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.
If you are posting source code with your question, place it inside <pre></pre> tags. We advise you also check the "Encode "<" (and other HTML) characters when pasting" checkbox before pasting anything inside the PRE block, and make sure "Use HTML in this post" check box is checked.
Be courteous and DON'T SHOUT. Everyone here helps because they enjoy helping others, not because it's their job.
Please do not post links to your question into an unrelated forum such as the lounge. It will be deleted. Likewise, do not post the same question in more than one forum.
Do not be abusive, offensive, inappropriate or harass anyone on the boards. Doing so will get you kicked off and banned. Play nice.
If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums.
No advertising or soliciting.
We reserve the right to move your posts to a more appropriate forum or to delete anything deemed inappropriate or illegal.
I am struggling to get out from this exception. I don't know why it is thrown always. My service( server) installed correctly from insaller and it is running in the background. But server has exposed the end points in a way:
But as soon as I send test data after opening the service, to the very first end point exposed by server. it throws the following exception
There was no at net.tcp://localhost:8732/PlcInputService a listening endpoint available that could accept the message. This is often caused by an incorrect address or SOAP action. For more details, see "InnerException", if any.
When you self-host, the endpoint must be created by the code that is running the service. The configuration is not used because you are not running your WCF code within ASP.NET or IIS then -- it is standalone.
Hi, based on recommendations on this forum, I made a wcf application to serve my 2 applications that need data.
So my solution looks like this now:
Data Access Layer project
wcf service library project
viewmodel project that extracts data from the wcf service library
a wpf application that binds to viewmodels from the viewmodel project
a test app that tests the wcf service & models
a web app that provides input for some of the models
The unit tests I made to test the wcf works perfectly as long as the service is up and running.
The wpf application fails to run as soon as I try to use the wcf service though. Always same thing: can't find the endpoint.
So when I use the models in the test app, everything works fine, when I use the same models in my wpf app, they throw exceptions as soon as they contact the wcf service. Same problem when my webapplication does this.
Can someone help me out please?
InvalidOperationException happens in following code when I call the constructor of the client:
InstanceContext context = new InstanceContext(this);
client = new LezingenServiceClient(context, "lezingen");
bij System.ServiceModel.Description.ConfigLoader.LoadChannelBehaviors(ServiceEndpoint serviceEndpoint, String configurationName)
bij System.ServiceModel.ChannelFactory.ApplyConfiguration(String configurationName, Configuration configuration)
bij System.ServiceModel.ChannelFactory.ApplyConfiguration(String configurationName)
bij System.ServiceModel.ChannelFactory.InitializeEndpoint(String configurationName, EndpointAddress address)
bij System.ServiceModel.DuplexChannelFactory`1..ctor(Object callbackObject, String endpointConfigurationName, EndpointAddress remoteAddress)
bij System.ServiceModel.ClientBase`1.CreateChannelFactoryRef(EndpointTrait`1 endpointTrait)
bij System.ServiceModel.ClientBase`1..ctor(InstanceContext callbackInstance, String endpointConfigurationName)
bij System.ServiceModel.DuplexClientBase`1..ctor(InstanceContext callbackInstance, String endpointConfigurationName)
bij Model.LezingenService.LezingenServiceClient..ctor(InstanceContext callbackInstance, String endpointConfigurationName) in d:\Programmeren4\TaakLezingen\Model\Service References\LezingenService\Reference.cs:regel 626
bij Model.CursistDepository..ctor() in d:\Programmeren4\TaakLezingen\Model\CursistDepository.cs:regel 33
Configuration files below:
app.config of service library project:
<?xmlversion="1.0"encoding="utf-8"?><configuration><configSections></configSections><connectionStrings><addname="LezingenService.Properties.Settings.home"connectionString="Data Source=localhost;Initial Catalog=Programmeren4_TaakMVVM;Integrated Security=True"providerName="System.Data.SqlClient"/></connectionStrings><appSettings><addkey="aspnet:UseTaskFriendlySynchronizationContext"value="true"/><addkey="ClientSettingsProvider.ServiceUri"value=""/></appSettings><system.web><compilationdebug="true"/><membershipdefaultProvider="ClientAuthenticationMembershipProvider"><providers><addname="ClientAuthenticationMembershipProvider"type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=18.104.22.168, Culture=neutral, PublicKeyToken=31bf3856ad364e35"serviceUri=""/></providers></membership><roleManagerdefaultProvider="ClientRoleProvider"enabled="true"><providers><addname="ClientRoleProvider"type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=22.214.171.124, Culture=neutral, PublicKeyToken=31bf3856ad364e35"serviceUri=""cacheTimeout="86400"/></providers></roleManager></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. -->
<!-- To avoid disclosing metadata information,
set the values below to false before deployment -->
<!-- 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 -->
we are developing an mobile application and we have used WCF service to fetch SQL Server data through online.
We are trying to authenticate each WCF Service call(server) by passing headers from client (mobile application). For this we have generated a token and passed the same in headers of each client call.
We have stored the tokens in HttpRuntime.Cache. But after few minutes [in idle mode] the cache entry is cleared.
Note: If continuously server and client communicates, it works perfectly.
I am calling a wcf service that returns a complex type response. How can i get that response and cast into some array list or string array to iterate the items. or is there any other way i can get complex type reponse?
I'm new in WCF.
And I would like to create a web site using WCF + JQuery.
What I have in mind is to have
JQuery + HTML5 as my Presentation Layer
WCF as Web Services that connect with JQuery
Dll as Business Logic Layer which work with WCF
EF6 as Data Access Layer
MSSQL as Database
Is this the way to do it?
Or to have everything inside WCF and remove the dll and Ef6?
From what I've read thus far, I think that WCF can achieve this. I'm just trying to wrap my head around the best option within WCF to use.
My servers and many clients are on the subnet 10.0.1.NNN, and other clients are on 10.0.2.NNN, 10.0.3.NNN, 10.0.4.NNN, 10.0.5.NNN, and 10.0.6.NNN. Every client has a static IP (no DHCP).
From what I presently understand, the P2P mesh option in WCF would not work in this, as the mesh option seems only to work within the same subnet. Correct me if I'm wrong.
In short, I'm in search of a "push" methodology vs. my present "pull" methodology. That being, the server "pushes" data to the client dynamically (when the data arrives at the server) vs. the client "pulling" the data from the server via a .NET timer being fired every NN minutes by 60+ workstations, with each workstation having 5+ apps running. That's 3500+ hits on the database per hour. A push method would reduce this to about 400 hits/hour.
What I currently conclude the option to be is that each client registers that it is "available" to receive msgs from the server. The server, when it receives data from another server activity, it needs to send info/data to the client. The client gets the data and takes appropriate action.
1) Do I need to "register" the client is available to receive msgs/data from the server? Candidly, I'd prefer to say away from "registering"/"unregistering".
2) Or, can the client merely have a WCF [server] channel open and the server check to see if that client's WCF channel is open to then send a msg/data? Note: The msg/data from the server to the client needs only be one-way.
Separate, though similar:
We do have a Chat app that uses older TCP/IP methods (.NET 1.1 dayz....) and does register/unregister with a main server.
I'd prefer to change it so that when the client chat app is opened, it can query to see which other clients are open to list as being "available" to chat with.
The good thing in both of these above is that we have a separate VMS-based system that everyone "logs" into (via a windows app or terminal via a windows telnet app) at the beginning of the day. This system identifies which IP address a given staff person is at. We can query this system in Windows to find out who is at which IP address, including multiple IP addresses.
As such, Windows (.NET) can get a list of "active" staff/IP addresses and then check those specific IP addresses for any WCF services available to connect into. OR so, I'm hoping is possible within WCF.
From what I've learned thus far of WCF, I prefer to do the entire binding in code and not via some .config file with each client.
I have made a WCF server and a client based on compact framework 3.5,while the client call the service,it always result in a EndPointNotFoundException which is "There was no endpoint listening at http://127.0.0.1:8731/Design_Time_Addresses/WcfDemoService/GreetingService/ that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details."
I can not find out the reason...could someone give me hand?
The following are the sources
WCF Server side
in main function:
staticvoid Main(string args)
ServiceHost host = new
Console.WriteLine("Server Opened !");
if (host.State == CommunicationState.Faulted)
Thanks for your time~
Finally,It connected successfully when I put the client program on my WinCE device!
But the problem still exist while using emulator which is on the desktop same as the wcf server.
I still can not figure out the reason...
WCF Application is working ok. but when i use the visual studio access my machine remotely. the service channel fault state exception is coming always. have to change any setting to resolve this issue..Thanks..