I am having trouble with a server that is not returning the time zone offset in a Web service response. From what I've read on the internet, it should always return the time zone offset. I need it but it is missing. It works on my local development machine but not on my test server. Both are set for Eastern Time GMT-5 (4 right now because of daylight savings time).
Below is my test code (.Net 1.1):
Local development machine
Windows XP
Visual Studio 2003
IIS 5.1
Test machine
Windows Server 2003
IIS 6.0
Response From Local Development machine
Response From Test machine
Notice that the response from the test machine is not returning the time zone offset.
Note that this does appear to be happening on our production machine which is also a Server 2003 (IIS6) machine, but I have not been thorough test with it yet.
Does anyone have any thoughts on this? I've searched Google and all I seem to find are people who are getting the offset and do not want it. I'm not getting the offset and do want it.
Pat B
Below is my test code (.Net 1.1):
Code:
<WebMethod(Description:="Testing Time Zone Offset", EnableSession:=False, CacheDuration:=0)> _
Public Function GetTime() As DateTime
Dim d As DateTime = #5/28/2009 8:00:00 AM#
Return d
End Function
Local development machine
Windows XP
Visual Studio 2003
IIS 5.1
Test machine
Windows Server 2003
IIS 6.0
Response From Local Development machine
Code:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="[URL unfurl="true"]http://schemas.xmlsoap.org/soap/envelope/"[/URL] xmlns:xsi="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema-instance"[/URL] xmlns:xsd="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema">[/URL]
<soap:Body>
<GetTimeResponse xmlns="https//portal.bccsoftware.com/webservices/WMM/">
<GetTimeResult>2009-05-28T08:00:00[red].0000000-04:00[/red]</GetTimeResult>
</GetTimeResponse>
</soap:Body>
</soap:Envelope>
Response From Test machine
Code:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="[URL unfurl="true"]http://schemas.xmlsoap.org/soap/envelope/"[/URL] xmlns:xsi="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema-instance"[/URL] xmlns:xsd="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema">[/URL]
<soap:Body>
<GetTimeResponse xmlns="https//portal.bccsoftware.com/webservices/WMM/">
<GetTimeResult>2009-05-28T08:00:00</GetTimeResult>
</GetTimeResponse>
</soap:Body>
</soap:Envelope>
Notice that the response from the test machine is not returning the time zone offset.
Note that this does appear to be happening on our production machine which is also a Server 2003 (IIS6) machine, but I have not been thorough test with it yet.
Does anyone have any thoughts on this? I've searched Google and all I seem to find are people who are getting the offset and do not want it. I'm not getting the offset and do want it.
Pat B