K
kishor
I have a following problem... I am looking for best and efficient solution
for this problem.
I have following entities ..(c#)
public class Dog
{
.... some Properties and methods.....
Dogs _friendDogs = new Dogs() ;
Public Dogs Friends()
{
get
{
return _friendDogs;
}
set
{
_friendDogs= value;
}
}
}
Public class Dogs : CollectionBase
{
........
}
When I am working with Dog and Dogs its is working fine without any error in
same project but when I am passing this entity through web service
I get an error because webservice convert this dogs to some array list and
cant be converted back to entity.
[WebMethod]
public Dogs GetFriendsDog()
{
.......
Return Dogs
}
Problem comes here on the following last line
Dogs somedogs = new Dogs();
somedogs = somewebService.GetFriendsDog() ;
Please suggest best method for this.
Regards
Kishor
for this problem.
I have following entities ..(c#)
public class Dog
{
.... some Properties and methods.....
Dogs _friendDogs = new Dogs() ;
Public Dogs Friends()
{
get
{
return _friendDogs;
}
set
{
_friendDogs= value;
}
}
}
Public class Dogs : CollectionBase
{
........
}
When I am working with Dog and Dogs its is working fine without any error in
same project but when I am passing this entity through web service
I get an error because webservice convert this dogs to some array list and
cant be converted back to entity.
[WebMethod]
public Dogs GetFriendsDog()
{
.......
Return Dogs
}
Problem comes here on the following last line
Dogs somedogs = new Dogs();
somedogs = somewebService.GetFriendsDog() ;
Please suggest best method for this.
Regards
Kishor