Hello Yolande,
You need to manually check if lngMiles is within range and throw a SoapException
if there is a problem.
if(lngMiles<0 || lngMiles>100)
{
SoapException se = new SoapException("Out of Range. Miles must be between
0 and 100",...);
se.Detail = "<Error><Code>100</Code><Description>Out of Range. Miles
must be between 0 and 100</Description></Error>";
throw se;
}
-Trevor
> Hi there,
>
[quoted text clipped - 9 lines]
>
> Yolande
erymuzuan - 21 Feb 2005 23:38 GMT
Remember that WSDL is your contract, and if you want this in you your
contract then you should say so. If you're not keen in writing WSDL
first, get Chritian weyer Contract first add -in.
or you can save your WSDL(auto gen.) go to to types where it says
<xs:element name="lngMiles" type="xsd:int"/>
change this to
<xs:element name="lngMiles">
<xs:simpleType>
<xs:restriction base="xs:int">
<xs:minInclusive value="0"/>
<xs:maxInclusive value="100"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
then save it in your web dir. Disable web services documentation in
web.config. let your user use this new wsdl file.
for the validation you can use SoapExtension, see this article
http://msdn.microsoft.com/msdnmag/issues/02/11/XMLFiles/default.aspx
regards
erymuzuan mustapa
> Hello Yolande,
>
[quoted text clipped - 25 lines]
>>
>> Yolande