vinayaki mishra

vinayaki mishra

  • NA
  • 1
  • 3.1k

OpenWriteAsync to pass a complex type object

Jun 15 2011 3:06 AM
Hi,

I have data contract
class Student()
{
   ...
public int Age{get;set;}
Public string Name{get;set;}

}

Now i have a rest web service and like
public Student UpdateData(Student s)
{
    s.Name="Roma";
        return s;

}

Now at client side i.e at MainPage.xaml.cs using webclient i want to pass
Student stu=new Student(){Name="hi",Age30};

stu object to my service to call UpdateData... How can i do that... any help would be appreciated... Thanks in Advance!!




Answers (1)