function onAppointmentWindowOpen(args) {
---------------
---------------
if (!ej.isNullOrUndefined(args.appointment)) {
$("#customId").val(args.appointment.Id);
$("#subject").val(args.appointment.Subject);
$("#customdescription").val(args.appointment.Description);
var ownerObject = $("#Owner").data("ejAutocomplete"); // here creating th object for auto complete control
var ownerValue = ej.DataManager(ownerObject.model.dataSource).executeLocal(new ej.Query().where("id", "equal", args.appointment.OwnerId))[0]["text"]; // here we are filtering the owner value based on the id
$("#Owner").ejAutocomplete("clearText");
$("#Owner").ejAutocomplete({ text: ownerValue, value: ownerValue }); // here we are binding the owner value to auto complete field
---------------
---------------
}
$("#customWindow").ejDialog("open");
}
else
$("#customWindow").ejDialog("open");
}
</Code>
We have checked the provided code example and found that you are trying to convert the auto complete field value in to date object which may be the cause for the issue. We request you to give the value to auto complete field as shown below.
<Code>
$("#AssesmentTypeID").ejAutoComplete({ value:args.appointment.AssesmentTypeID });
</Code>
Kindly try with the above suggestion and if still issue persist at your end try to reproduce the error in the above sample and send it back to us or you can share sample, if possible. We can analyze the mentioned scenario and provide you the possible solution.
Regards,
Karthigeyan