# DATAPICKER DIFFERENT PROBLEM

**URL:** <https://forums.fusetools.com/t/datapicker-different-problem/4122>\
**Category:** Bug Reports\
**Created:** [January 18, 2018, 10:35am UTC](https://forums.fusetools.com/t/datapicker-different-problem/4122 "2018-01-18T10:35:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![toto007](https://avatars.discourse-cdn.com/v4/letter/t/e19adc/32.png) [@toto007](https://forums.fusetools.com/u/toto007)\
**Post date:** [January 18, 2018, 10:35am UTC](https://forums.fusetools.com/t/datapicker-different-problem/4122/1 "2018-01-18T10:35:23Z")

</div>

Fuse 1.5.0 MacOs

The first problem  
If I use `DataPicker` setting properties minData/maxDate on Android device (v 4.4.2) my app crash with this exception:

```auto
Uno.Exception: java.lang.IllegalArgumentException: fromDate: Mon Jan 01 00:00:00 CET 1900 does not precede toDate: Mon Jan 03 00:00:00 CET 1

```

Reproduce ISSUE:

```auto
<StackPanel>
    <JavaScript>
        var Observable = require("FuseJS/Observable");

        var someDate = Observable(new Date(Date.parse("1950-02-14T00:00:00.000Z")));

        someDate.onValueChanged(module, function(date) {
            console.log("someDate changed: " + JSON.stringify(date));
        });

        module.exports = {
            someDate: someDate,

            minDate: new Date(Date.parse("1900-01-01T00:00:00.000Z")),
            maxDate: new Date(Date.parse("2000-01-01T00:00:00.000Z")),

            whoYouGonnaCall: function() {
                someDate.value = new Date(Date.parse("1984-06-08T00:00:00.000Z"));
            }
        };
    </JavaScript>

    <NativeViewHost>
        <DatePicker Value="{someDate}" MinValue="{minDate}" MaxValue="{maxDate}" />
    </NativeViewHost>

    <Button Text="Who you gonna call?" Clicked="{whoYouGonnaCall}" Margin="5" />
</StackPanel>

```

The second problem  
If I use datapicker without setting the properties minmax, I however it don’t work correctly. The ui datapicker is shifted and I see only January and February as a selection option

 ![file](https://s3.us-east-2.amazonaws.com/fuse-legacy-forum-assets/xAdvOLcHmaIE-image-1516271008547.JPG)  
Reproduce issue

```auto
<App>
	<StackPanel>

	    <NativeViewHost>
	        <DatePicker />
	    </NativeViewHost>

	</StackPanel>
</App>

```

---

<div class="post-metadata">

**Author:** ![Enrico](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/enrico/32/144_2.png) [@Enrico](https://forums.fusetools.com/u/Enrico)\
**Post date:** [February 5, 2019, 12:27pm UTC](https://forums.fusetools.com/t/datapicker-different-problem/4122/2 "2019-02-05T12:27:31Z")

</div>

Datepicker in Fuse 1.9 has the same `minDate` / `maxDate` issue.

---

<div class="post-metadata">

**Author:** ![aeq](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/aeq/32/129_2.png) [@aeq](https://forums.fusetools.com/u/aeq)\
**Post date:** [February 7, 2019, 7:46am UTC](https://forums.fusetools.com/t/datapicker-different-problem/4122/3 "2019-02-07T07:46:43Z")

</div>

I don’t understand the issues; just set a reasonable min and max date?

Its a component that picks dates, the dates need to exist, hence the range is required.

Unless y’all complaining about defaults needing to be set for yo lazy asses? 😛
