B
Brian Steiner
I have the following sample asp.net webservice:
....
namespace x
{
[WebService(Namespace="mynamespace")]
public class WS : System.Web.Services.WebService
{
...
public class Class1
{
public string s;
}
public class Class2
{
public string s;
}
public class Class3
{
public string s;
public Class1 c1;
public Class2 c2;
}
public string Test(Class3 c3)
{
}
}
}
When I use XmlSerializer to deserialize the webreference proxy for Class3,
it includes namespace attributes for Class3.s, Class3.c1, and Class3.c2. If
I set the namespace attribute of the webservice to "" and update the
webreference, the webreference proxy no longer works. How can I tell the
webservice to ignore the namespace attribute for all public types in Class3?
....
namespace x
{
[WebService(Namespace="mynamespace")]
public class WS : System.Web.Services.WebService
{
...
public class Class1
{
public string s;
}
public class Class2
{
public string s;
}
public class Class3
{
public string s;
public Class1 c1;
public Class2 c2;
}
public string Test(Class3 c3)
{
}
}
}
When I use XmlSerializer to deserialize the webreference proxy for Class3,
it includes namespace attributes for Class3.s, Class3.c1, and Class3.c2. If
I set the namespace attribute of the webservice to "" and update the
webreference, the webreference proxy no longer works. How can I tell the
webservice to ignore the namespace attribute for all public types in Class3?