Hi,
I am using the following code and have difficulties when I add this line “$(”#x_FDatum").datepicker(“setDate”, “+5”);" to set the date for the Field “FDatum”.
This should help to set the date +5 days in datepicker.
Is there an example for such case?$(“#x_Status”).change(function() {
var str = $(“option:selected”, this);
if (this.value == “Pruefung”) {
$(“#r_SME1”).show(“slow”);
$(“#r_SME2”).hide(“slow”);
$(“#r_Grund”).hide(“slow”);
$(“#x_FDatum”).datepicker(“setDate”, “+5”); // <==
$(this).fields(“SME1”).value(<?= CurrentUserID() ?>); // Set value to FieldA
}thanks.
mpol_ch
mpol_ch wrote:
$(“#x_FDatum”).datepicker(“setDate”, “+5”); // <==
Did you mean .datetimepicker() or are you using another date time picker? If you use .datetimepicker(), there is no “setDate” option, you may see the available Options.Also see Usage, if you use input group, the date time picker is created at the div.input-group, not at the input element (e.g. “#x_FDatum”).