2008/09/03

Use WCF in Silverlight 2

I don't know why I have to set BasicHttpBinding, and EndpointAddress parameters while calling WCF.

In silverlight tutorial always use below:
Dim client As New ServiceReference1.SimpleWCFClient ()

BUT, I have to declare like below syntax to make it work. It is not so dynamic coding, since I have to give the WCF file URL.

Dim client As New ServiceReference1.SimpleWCFClient ( _
New BasicHttpBinding, _
New EndpointAddress("http://localhost/SilverlightApp_Web/SimpleWCF.svc") _
)

沒有留言: