473,794 Members | 2,729 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to send 10/29/06 01:30 CST? - WebServices,Dat eTimes, and Timez

(Sorry if this is a duplicate post. I'm not sure if my newsreader was set up
right.)
---------------------------------
My computer is a client in the central timezone with daylight savings.

I need to pass a time and a value to the server via webservices (for
example, the price of electricity at each hour in the future). Suppose I
want to send these four times and values to the server:
2006-10-29 05:30 GMT, $1.50
2006-10-29 06:30 GMT, $1.60
2006-10-29 07:30 GMT, $1.23
2006-10-29 08:30 GMT, $1.35

Since my computer is in the central timezone, there is no way I can find to
create a time equivalent to the 7:30 GMT time. It should interpret these
times as:
12:30 AM CDT (05:30 GMT)
1:30 AM CDT (06:30 GMT)
<----- (clocks roll back to standard time)
1:30 AM CST (07:30 GMT)
2:30 AM CST (08:30 GMT)

Based on my observations with the .ToUniversalTim e method, you get only
these times:
12:30 AM CDT (05:30 GMT)
1:30 AM CDT (06:30 GMT)
2:30 AM CST (08:30 GMT)
7:30 GMT can't be represented.
Similarly, 6:30 GMT can't be represented on a client in the eastern time zone.

How can I send the missing hour to a webservice? I can't change the time on
the client machine and I can't change the server side method to accept a
different data type.

The only solutions I can think of so far are to set my app to run in a
timezone that doesn't use daylight savings (I'm not sure it that is possible
without changing the client's system clock) or override the
deserialization/serialization to get/set the timezone part of the xml
message. I don't know how to do either of these, so I hope there is a simple
example somewhere or a different option.

I realize I'll have to handle timezone conversions within my client code.
Assuming I can keep things straight, however, my main concern is being able
to communicate an instant in time to the server when it falls within the
first hour of the switch back to "standard time".

Please advise. Thank you

Mar 3 '06 #1
0 1045

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
983
by: Michael Pfeifer | last post by:
Hi all, I need to convert datetimes from any timezone to UTC and back considering daylight saving. It is not enough, to just add or subtract the timezone offset. Also, I can not use c functions and structures like localtime and time_h, since they only can handle datetimes "younger" than 01/01/1970. I need to handle birthday dates also. I tried to integrate Boost libraries (see www.boost.org), but I was not able to get them running...
8
4014
by: Komandur Kannan | last post by:
We have a smart device application running on handhelds(Symbol MC9000G). The backend is Oracle and a middle tier web services development done in Vb.net. We use pessimistic Locking due to specific business needs When such a lock is made for a transaction (this code is in the web service) and the handhelds are terminated abnormally (cold booted or battery low), the lock still remains. The Web service's connection to oracle is still...
0
1004
by: Bill | last post by:
My computer is a client in the central timezone with daylight savings. I need to pass a time and a value to the server via webservices (for example, the price of electricity at each hour in the future). Suppose I want to send these four times and values to the server: 2006-10-29 05:30 GMT, $1.50 2006-10-29 06:30 GMT, $1.60 2006-10-29 07:30 GMT, $1.23 2006-10-29 08:30 GMT, $1.35 Since my computer is in the central timezone, there is no...
3
1819
by: Pieter Coucke | last post by:
Hi, For some reason, somewhere in my application 1 hour is added to my dates, depending in which time zone the application is run... Because I don't have a clue where this happens, I posted this to the three relevant newsgroups (vb/ado, sql and xml): my aplogize for this. I'm doing a Synchronisation between two SQL Servers (2000): All the Data is read into a DataSet, and exported to an XML-file: SQL Server -> DataSet (VB.NET 2003) ->...
0
9671
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9518
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10212
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10161
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10000
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7538
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5436
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4112
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3720
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.