Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

WebServices won't run?
k0ren
#1 Posted : Sunday, April 26, 2009 10:35:02 AM(UTC)
Groups: Member
Joined: 4/26/2009(UTC)
Posts: 4
Location: bg

Hi,
I have created a test silverlight app with an asp.net site from the template in vs2008. Then I have added some webservices directly into the web site project. When I run the app from vs the services are working. When I register the site with cassini and try to navigate it with my actual IP address the services are not called at all.



Ultidev Team
#2 Posted : Sunday, April 26, 2009 11:28:43 AM(UTC)
Ultidev Team

Groups: Administration
Joined: 11/3/2005(UTC)
Posts: 2,253

Thanks: 28 times
Was thanked: 60 time(s) in 59 post(s)
Hi there.

Could you please confirm that you have downloaded and are using UltiDev Cassini Web Server, and not Microsoft Development web server that comes with Visual Studio? We ask this because Microsoft Development web server can only serve requests send to the loopback address (localhost or 127.0.0.1). If you are using UltiDev Cassini, please take a look at Windows Event Log for any error entries related to UltiDev Cassini.

Best regards,
UltiDev Team.
Please donate at http://www.ultidev.com/products/Donate.aspx to help us improve our products.
k0ren
#3 Posted : Monday, April 27, 2009 11:04:22 AM(UTC)
Groups: Member
Joined: 4/26/2009(UTC)
Posts: 4
Location: bg

I solved my problem so if anyone is trying to make and host silverlight application first must read carefully this.

In short - silverlight app can make calls to resources such as databases through web services. I successeded to host only 'WebService' (asmx file) with cassini, not 'Silverlight Enabled Wcf Service' (svc file) nor 'Ajax Enabled Wcf Service'.

Here is the process step by step:

1 Create Silverlight project for the app itself (the interface).

2 Create another Silverlight project for the WebServices (it might be differet type of project but this works fine).

3 Add the 'clientaccesspolicy.xml' to the root where the web services are (the content of this file is in the above link).

4 Host the web services project with cassini and give him static port. Test the service, just type http://yourStaticIP:yourStaticPort/yourWebService.asmx

5 Host the Silverlight app those with the interface.

6 Add the newly created service to the app's coresponding web site. Use your path with the static port when searching for the service (http://yourStaticIP:yourStaticPort/yourWebService.asmx).

Hope that helps. Take care!
Ultidev Team
#4 Posted : Monday, April 27, 2009 6:55:34 PM(UTC)
Ultidev Team

Groups: Administration
Joined: 11/3/2005(UTC)
Posts: 2,253

Thanks: 28 times
Was thanked: 60 time(s) in 59 post(s)
Thank you much for the information!

The reason why you were only able to use ASMX but not WCF is explained in this FAQ article.

Best regards,
UltiDev Team.
Please donate at http://www.ultidev.com/products/Donate.aspx to help us improve our products.
Rss Feed  Atom Feed
Users browsing this topic
Guest (2)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You can vote in polls in this forum.