views:

59

answers:

0

I already searched a lot in Google. I created a EntityClass on client side, and then I added the library reference of this class on Web Service side. But when I want to call the method, it shows this error:

Error 2 Argument 1: cannot convert from 'Services_Library.UserService.UserServiceSoapClient' to 'Services_Library.UserService.UserEntity'

here is the code where the compiler says the error:

public void test(UserEntity userEntityx)
{
  UserService.UserServiceSoapClient userService = new UserService.UserServiceSoapClient();
  userService.testUserAsync(new UserEntity());
}

the web service code is this:

[WebMethod]
public void testUser(UserEntity userEntity)
{
  UserEntity newUser = new UserEntity();
  newUser.id = userEntity.id + 10;
}

I guess I dont need to use explicity serialization, so how can I do this please? Thank you. obs: I'm devoloping for a Windows Phone.