Given:
- An asmx web service.
- A 3rd party dll that contains a useful enum.
Question:
How can I expose this enum through my web service without having to repeat myself and re-type the enum's members in my webservice's public class?
Given:
Question:
How can I expose this enum through my web service without having to repeat myself and re-type the enum's members in my webservice's public class?
You can create a method which either takes or returns a value with their enum in it. The namespace on the enum will change to your service namespace when they generate the proxy class, but you'll have the values they input on your end. This shouldn't be a problem though as long as they aren't trying to use the same enum in your service and the third party.