819 reputation
816
bio website
location
age
visits member for 2 years, 9 months
seen 23 hours ago

2d
revised How to copy calculated field formula client-side?
edited title
2d
asked How to copy calculated field formula client-side?
Sep
25
awarded  Taxonomist
Aug
14
revised Open Quick Launch link in new window (CSOM)
added 170 characters in body
Aug
14
revised Open Quick Launch link in new window (CSOM)
edited body
Aug
14
revised Open Quick Launch link in new window (CSOM)
added 552 characters in body
Aug
14
asked Open Quick Launch link in new window (CSOM)
Aug
11
awarded  Inquisitive
Jul
8
awarded  Popular Question
Jul
5
revised Add Document Library XsltListViewWebPart using CSOM or web services
deleted 16 characters in body
Jul
3
awarded  Popular Question
Jul
2
awarded  Curious
Jun
17
awarded  Notable Question
Jun
15
comment Set DateTime (utc) to listitem (CSOM, SP2013)
Are you sure you don't have UTC+0 in the web's locale? I checked from database that SharePoint and saves the UTC value to the database (after internally converting the given value from web's timezone (which it expects client to give) to UTC). And on-prem SP2013 seems to do no conversions when client reads the value, resulting in client getting the converted UTC value.
Jun
15
comment Set DateTime (utc) to listitem (CSOM, SP2013)
If you first save a value and then retrieve it, you will get a different value than you inserted: The value you get is converted to UTC, right? (on-premises at least it seems to work like this)
Jun
15
accepted Set DateTime (utc) to listitem (CSOM, SP2013)
Jun
15
comment Set DateTime (utc) to listitem (CSOM, SP2013)
so.. I guess 'listItem["DateTime"] = utc;' would not save utc because sharepoint converts the value to utc before saving. Otherwise your answer seems to work great :-) can we be sure the replacement will always be valid?
Jun
15
comment Set DateTime (utc) to listitem (CSOM, SP2013)
SharePoint seems to store UTC of the given local time to the database so saving 4pm in UTC+3 timezone would get stored as 1pm. Thus we get 1pm when reading the value (var value = listItem["DateTime"]; // 1pm)
Jun
14
revised Set DateTime (utc) to listitem (CSOM, SP2013)
edited title
Jun
14
revised Set DateTime (utc) to listitem (CSOM, SP2013)
edited title