The following code gives me an error:
var frmObj = forms.frmJournalModify;
frmObj.controller.find();
frmObj.entry_date = "18-12-2002...01-01-2003|dd-MM-yyyy";
frmObj.controller.search();
The error is as follows:
java.lang.IllegalArgumentException: Setting dataprovider with name ‘entry_date’ / type ‘DATETIME’ with value of wrong type 18-12-2002…01-01-2003|dd-MM-yyyy (_test2, line 4)
The error does not occur if I did the search manually.
Servoy Developer
Version 3.0b3-build 364
Java version 1.5.0_04-b05 (Windows XP)
faheemhameed:
The following code gives me an error:
var frmObj = forms.frmJournalModify;
frmObj.controller.find();
frmObj.entry_date = “18-12-2002…01-01-2003|dd-MM-yyyy”;
frmObj.controller.search();
> The error is as follows:
> java.lang.IllegalArgumentException: Setting dataprovider with name 'entry_date' / type 'DATETIME' with value of wrong type 18-12-2002...01-01-2003|dd-MM-yyyy (_test2, line 4)
The error does not occur if I did the search manually.
Are you sure you’re using the correct syntax?
Shouldn’t it be something like:
var formattivo = 'frmJournalModify'
forms[formattivo].controller.find()
forms[formattivo].datefield = "18-12-2002...01-01-2003|dd-MM-yyyy";
forms[formattivo].controller.search()
Both your and my syntax are correct. My coding is working in the previous versions but just not in the latest version
Servoy Developer
Version 3.0b3-build 364
Java version 1.5.0_04-b05 (Windows XP)
What is the datatype of entry_date inside the db when looking at it with a db tool?
What does your stacktrace say when your script is fired?
I have checked the type of the field entry_date through sysbase central and it is “datetime”. I will check the stacktrace and send it to you later.
Thanks,
Servoy Developer
Version 3.0b3-build 364
Java version 1.5.0_04-b05 (Windows XP)