Select to view content in your preferred language

Editing Date in AttributeInspector BUG?

1561
11
11-04-2010 05:08 PM
JoseSousa
Esri Contributor
Dear ArcGIS API for Flex Team,

I've created a simple MXD just with a single layer and field named DATE of type Date.
I've published to MXD as Feature Service.

I'm using your out-of-the-box ArcGIS Web Map Viewer for Flex and the editing widget point to this Uri.

When I create or update features and edit the Date attribute the date that is stored in the database is always one day before the date I have specified. For instance, if I specify 6 of November it will put in the Database 5 of November. I've read your code on the Widget and it references to a bug on REST API.

(your comments on the EditWidget.mxml)
var date:Date = new Date(feature.attributes[field.name]);
if (date.milliseconds == 999)
{
     date.milliseconds++;  //Add 1ms to date values ending in 999 to workaround REST date bug                               
     feature.attributes[field.name] = date.time;
}

I have tested this behaviour with AGS API for Silverlight and it happens the same way.

Our date and time settings are (UTC + 12:00) Auckland, Wellington and I am thinking that the API isn't supported. I hope I am wrong.

Can you provide me a solution or an workaround? This is an important feature.

With regards,
José
Tags (2)
0 Kudos
11 Replies
RobertScheitlin__GISP
MVP Emeritus
Rachel,

   Based on this GitHub entry, it looks like this will be addressed in 3.4.

https://github.com/Esri/arcgis-viewer-flex/issues/127
0 Kudos
RachelS
Frequent Contributor
Hi Robert,
Thanks for that, good to see it'll be fixed.
Rachel
0 Kudos