Unable to create features in FeatureLayer when adding an attribute of type date.
上次发布: May 23, 2019ArcGIS Runtime SDK
漏洞 ID 编号
BUG-000122250
已提交
May 8, 2019
上次修改时间
June 5, 2024
适用范围
ArcGIS Runtime SDK
找到的版本
100.5
操作系统
Android
操作系统版本
N/A
状态
Will Not Be Addressed
开发团队已考虑过该问题或请求,并决定不会解决该问题。 问题的“其他信息”部分可能包含进一步说明。
附加信息
The DATE field is of Type Java Calendar so when editing or creating new features, the Calendar object must be used for the date field: https://developers.arcgis.com/android/latest/api-reference/reference/com/esri/arcgisruntime/data/Field.Type.html#DATE
Example:
DateFormat sdf= new SimpleDateFormat("MM/dd/yyyy hh:mm:ss a");
String dateInString="05/05/2019 10:20:56 AM";
Date date= (Date) sdf.parse(dateInString);
Calendar calendar = Calendar.getInstance();
calendar.setTime(date);
attributes.put("DATE",calendar);