DatatypeFormats.p gives examples of how to format data for several
of the XML datatypes. It invokes the operation MultiDatatypes()in 
the web service http://localhost/DatatypeFormats/Service1.asmx.
The operation copies the input parmeter to the corresponding
output parameter.  The C# .NET web service is provided in 
$DLC\src\samples\webservices\4GLClient\DatatypeFormats\CS.NET\DatatypeFormats


This sample code gives examples of the formats that are
required by SOAP for the following XML Schema datatypes. 
 
    boolean    - true, false, 1, 0
    datetime   - 9999-99-99THH:MM:SS.SSS+HH:MM
    duration   - P99Y99M99DT99H99M99S
    gDay       - ---DD
    gMonth     - --MM--
    gMonthDay  - --MM-DD
    gYear      - YYYY
    gYearMonth - YYYY-MM

The operation MultiDatatypes() has the following input parameters:
Datatype    Parameter Name

Boolean 	paramIn1
DateTime 	paramIn2
duration	paramIn3
gDay		paramIn4
gMonth	paramIn5
gMonthDay	paramIn6
gYear		paramIn7
gYearMonth	paramIn8

The operation MultiDatatypes() has the following output parameters:
Datatype    Parameter Name

Boolean 	paramOut1
DateTime 	paramOut2
duration	paramOut3
gDay		paramOut4
gMonth	paramOut5
gMonthDay	paramOut6
gYear		paramOut7
gYearMonth  paramOut8


DIRECTIONS

To deploy this C# ASP.NET web service on your machine, at a minimum you need the 
.NET Framework runtime installed, which can be downloaded from Microsoft. 
The IIS web server must also be running. Directions for deploying a web service 
can be found at:

HOW TO: Deploy an ASP.NET Web Application Using Xcopy Deployment
http://support.microsoft.com/view/tn.asp?kb=301392 
HOW TO: Create a Virtual Directory in Internet Information Services (IIS) 
http://support.microsoft.com/view/tn.asp?kb=301392  

The steps in DatatypeFormats.p:

1) Create a web service object in the 4GL

2) Connect to the web service 

3) Set the handle to the WSDL's portType using  RUN xxx SET xxx ON SERVER xxx.

4) Create the XML document that will be passed to the input parameter
as a LONGCHAR. This operation requires that the input and output
parameters are XML documents because the web service is 
Document/Literal/Wrapped.
 
The web service is expecting the input parameter XML document to have
this structure:

<ns0:MultiDatatypes xmlns:ns0="http://tempuri.org/">
	<ns0:paramIn1>boolean-value</ns0:paramIn1>
      <ns0:paramIn2>dateTime-value</ns0:paramIn2>
      <ns0:paramIn3>duration-value</ns0:paramIn3>
      <ns0:paramIn4>gDay-value</ns0:paramIn4>
      <ns0:paramIn5>gMonth-value</ns0:paramIn5>      
	<ns0:paramIn6>gMonthDay-value</ns0:paramIn6>      
      <ns0:paramIn7>gYear-value</ns0:paramIn7>
      <ns0:paramIn8>gYearMonth-value</ns0:paramIn8>
</ns0:MultiDatatypes>

5) Save XML document as LONGCHAR.

6) Invoke the MultiDatatypes operation of the web service by making 
   a procedure call.

7) Check for errors

8) Load the XML document that was passed back in the Output parameter.

The output XML document will have the following structure:

<ns0:MultiDatatypesResponse xmlns:ns0="http://tempuri.org/">
	<ns0:paramOut1>boolean-value</ns0:paramOut1>
      <ns0:paramOut2>dateTime-value</ns0:paramOut2>
      <ns0:paramOut3>duration-value</ns0:paramOut3>
      <ns0:paramOut4>gDay-value</ns0:paramOut4>
      <ns0:paramOut5>gMonth-value</ns0:paramOut5>
      <ns0:paramOut6>gMonthDay-value</ns0:paramOut6>
      <ns0:paramOut7>gYear-value</ns0:paramOut7>
      <ns0:paramOut8>gYearMonth-value</ns0:paramOut8>
</ns0:MultiDatatypesResponse>

9) Parse the XML document.

10) Display the data that was extracted from the XML.

11) Clean up by doing the following:
	Delete the procedure object
	Disconnect from the web service
	Delete the web service object
