silverlight 5 and webservices RRS feed

  • Question

  • I have a Silverlight 5 app that runs in a browser.  It's been working for over a year.  When I look at the service referrence, it shows the address, access level is public, Data Type collection type is system.collections.generic.list and dictionary collection type is system.collections.generic.dictionary.

    The Silverlight app runs and will use the webservice.. that is until I modify the _DoWorkCompleted private sub that is called for the webservice call.  As soon as I modify that sub (something as simple as Dim x as string=string.empty), the webservice doesn't work anymore.  I get an error about it not being the same doc type.  When I go back to the webservice, all the information looks the same.  I tried to delete the service reference and recreate it and again it tells me that the doc types are different.  The webservice that I'm trying to connect to is on a public webserver.. nothing has changed on that end.. only thing changes is any code in the _DoWorkerCompleted.

    I need to modify the code in the _DoWorkCompleted event arg that takes place when the webservice call is complete.  This is the sub that if i modify it, it no longer wants to connect to the webservice. 

    Here is the code that creates the call...

    Dim client As New wsTypingTest.TypingTestClient

            AddHandler client.DoWorkCompleted, AddressOf client_DoWorkCompleted 

    Then i have the

    Private Sub client_DoWorkCompleted(ByVal sender As Object, e As wsTypingTest.DoWorkCompletedEventArgs)

    It is here.. on the DoWorkComplete that i need to update code.  So i'm not modifying the webservice referrence, i'm modifying some code but this modification seems to be what makes the webservice referrence no longer work.

    Tuesday, August 14, 2012 1:27 PM