valueReturns: string | datepicker object

Gets or sets the value of the datepicker.

Parameters

NameTypeDescription
value {string} The value that needs to be selected.

Examples

Get

    
 <button class="gj-button-md" onclick="alert($datepicker.value())">Get Value</button>
 <hr/>
 <input id="datepicker" width="312" />
 <script>
     var $datepicker = $('#datepicker').datepicker();
 </script>

  

Set

    
 <button class="gj-button-md" onclick="$datepicker.value('08/01/2022')">Set Value</button>
 <hr/>
 <input id="datepicker" width="312" />
 <script>
     var $datepicker = $('#datepicker').datepicker();
 </script>