Forum Discussion
7 Replies
- krisgopi88Ideator I
Hi
You can configure the time in the Item Type.
Long Date: Tuesday, January 14, 2019
Short Date: 1/14/2019
Short Date Time: 1/14/2019 9:30:43 PM (Allows User to Select Time)
Long Date Time: Tuesday, January 14, 2019 9:31:41 PM (Allows User to Select Time)- SathishIdeator I
This works for properties that are bound to an Item Type. But when you are creating a custom form and use a Date control in it, the default calendar that opens when clicking on the icon does not have Time field enabled... Any thoughts?
- christopher_gillisNew Member
Hello,
This is possible by passing a format parameter into the Date dialog when you open it. You can see all of the available parameters for the different standard Aras dialogs in this blog post. Your updated code will look something like the sample below.
var i18n = aras.IomInnovator.getI18NSessionContext()
var format = i18n.GetUIDatePattern("long_date_time"); // M/d/yyyy h:mm:ss a
var params =
{
// date: origDate, <-- You can use this to pass in a date you want the dialog to start at
format: format,
aras: top.aras,
type: 'Date',
title: 'Select Date',
dialogWidth: 250,
dialogHeight: 250
};
// Open the dialog and do all of your processing belowChris
Christopher Gillis
Aras Labs Software Engineer