1 of 1 people found this helpful
UpdateValue accepts a PITimeFormat object which can refer to a UTC time. One way is to set the UTCSeconds property of a PITimeFormat object and pass this into UpdateValues. Another way is to pass in a numeric representing seconds since 1970 UTC. You can find some examples under the UpdateValues section under the PIData object in the PI SDK guide (%pihome%\help\pisdk.chm).
My problem is that I want to use the application to load data for the day of 25 hours a few days after that day. So I can’t use UTC seconds property because it uses the current time to calculate UTCSeconds. It doesn’t take into account the date of the value to be loaded
De: Barry Shang
Enviado el: jueves, 10 de septiembre de 2015 19:20
Para: De Hoyos Ruiz, Jorge
Asunto: Re: - Update values in a PI Server with UTC time using VBA in Excel
Update values in a PI Server with UTC time using VBA in Excel
reply from Barry Shang<http://jiveon.jivesoftware.com/mpss/c/8AA/PDcDAA/t.1qb/t_4az7WYRvesKtqr_T7lbA/h1/IaY9gMzM3xUk5HD2sY85xvjFlx-2BYxUeU0PE0Zh0cAIUQzceR-2BoijELLskICLaRRYAqB7tifdiMj-2FyiomtP76IaJUxDx1XKUd4cGigIqJWQ4-3D> in PI Developers Club - View the full discussion<http://jiveon.jivesoftware.com/mpss/c/8AA/PDcDAA/t.1qb/t_4az7WYRvesKtqr_T7lbA/h2/IaY9gMzM3xUk5HD2sY85xhI13zIUgAzQlwPKlx1LmpBuLTKCOsLZyHbwQR57ri1NajgCb2ItfGgARt91S-2F6d3twWEhA-2F0UwslYDUY0Qzhno-3D>
You have written: "It doesn’t take into account the date of the value to be loaded". Are you referring to Daylight Saving Time?
UTC time in seconds is not influenced by DST. I guess this is the reason you have mentioned that you want to update values from a day with 25 hours, isn't it?
You can use UTC seconds in order to load data from any day. But you need to make sure that the requested time range is correct.
If you paste your code snippet, it would be easier to help you.