I cannot seem to access my WCF Service from Windows Phone Silverlight 8.1 application.
I am able to add a service reference, like for example in a console applications, but the following code does not work
ServiceReference1.MojaSmetkaWcfClient client = new MojaSmetkaWcfClient();
var result = client.GetData(0);
It says 'Cannot resolve symbol ServiceReference1'.
This works in a console app project. How can I connect to the WCF service. If it is not possible, are there any alternatives similar to WCF? Thanks
I have solved this by updating my VS2013 to Update 5 (maybe that didn't help solving the problem) and doing the following:
Right click on the service reference
Configure service reference
Uncheck 'Reuse types in referenced assemblies'
I use SharePoint 2013 and I create Secure Store Service App and remove it.
When I want create this Service Application with the same Pool Name I get this error :
This Server Application Pool already exist....
How can I remove an Application Pool in SharePoint 2013?
I found this post that also works for Share point 2013.
according to that, we can do this :
Launch the SharePoint 2010 Management Shell with administrator privileges
(Start -> All Programs -> Microsoft SharePoint 2010 Products -> Right click on SharePoint 2010 Management Shell -> Run as administrator).
Run 'Get-SPServiceApplicationPool'.
Run 'Get-SPServiceApplicationPool -Identity <"Name of the application pool">
Run ‘Remove-SPServiceApplicationPool’.
Input the Identity <"Name of the application pool">.
Input 'Y' to delete the application pool.
I'm trying to call an asmx service from a silverlight client but despite my best efforts I cannot get the generated proxy classes to be ObservableCollections, please help. I select ObservableCollection in the advanced configuration in the service reference, and I've tried updating the .svcmap file, but no success.
Any other ideas?
I don't have VS2012, but I am sure it should be same in VS2012 as of VS2010.
follow this steps
1) Add service reference (not web reference)
2) Go to Advanced Options
3) Choose Observale collection as option
4) You have your observale collection in proxy
After a Windows 7 fresh restart, I open the Visual Studio 2010 as administrator, create a new project of Windows Azure Project with ASP.NET Web Role, then at the WebRole1 project I add a WebService1.asmx and press F5 (run).
The Windows Azure services starts OK and the browser open the http:/127.0.0.1:8080/WebService1.asmx perfectly. But when I click at Invoke button to test the webservice method I always receive a Bad Request - Invalid Hostname, with a http:/127.0.0.1:8081/WebService1.asmx/HelloWorld.
The most likely cause is ASMX's WSDL file doesn't stand by load balanced environment such as Windows Azure. The test feature relies on WSDL. You will see similar issues if you add a web/service reference. It is recommended to upgrade to WCF. In WCF, you can use useRequestHeadersForMetadataAddress (http://msdn.microsoft.com/en-us/library/ee816894.aspx) to fix the issue. If you need to use ASMX, please try to manually provide a correct WSDL file.
I don't want WCF, I only want web service.
Thank you.
They've obscured it, but it's easy enough:
Right-click on your solution, select Add New Project.
In the Framework selection dropdown, select .NET Framework 3.5
Select the Web installed templates listing and you'll find ASP.NET Web Service Application as the last one in the list.
In other words, you can create one in .NET 3.5, but not 4. Now, that being said, it seems like it may be possible to create a .NET 4 template for VS2010, but I'm not a VS2010 guru, so that's for someone else to elaborate on.
Edited to Add: Somebody else posted a response to your question that was also a good answer, I thought, but they deleted it themselves for some reason. I don't remember their user name. I'll repeat it here.
If you create a new Web Application in the solution, you can then Add New Item, and one of the options under Web is "Web Service" at the very bottom.
The only drawback to this is that besides the web service, you also have the usual default items for a web application, namely default.aspx, about.aspx, global.asax, and site.master, as well as the folders Account, Scripts, and Styles. But you can delete these, so no problem. Also keep in mind that the web.config in the Web Application project will be different from that of the Web Service, and that the assembly bindings for the web service will point to ASP.NET v2 & v3.5 (see its web.config), whereas the service in the web application project will default to ASP.NET v4 (through its project file). I don't know if any negative implications exist for either way of working, though I suspect that both will work just fine.
If you select the framework like mentioned above to 3.5 you can select a web service application. If you want it to be targeted at .NET 4.0 framework, go into my project --> Compile --> Advanced Compile Options --> change the target framework to .net framework 4.
You can also change your compile options to target it at a x64 or x86 (32 bit) server.
web.config in the Web Application project will be different from that of the Web Service, and that the assembly bindings for the web service will point to ASP.NET v2 & v3.5 (see its web.config), whereas the service in the web application project will default to ASP.NET v4 (through its project file). I don't know if any negative implications exist for either way of working, though I suspect that both will work just fine.
Here was my resolution:
Right-click on your project name and select to Add Service Reference.
Select the Advance button at the very bottom.
Select the Add Web Reference button at the very bottom.
Proceed as usual. :)