|
|
Home » Community » Newbie corner » how to make an editfield accept only number or date? have any examples in the documentation?
|
|
|
|
|
|
|
|
|
Re: how to make an editfield accept only number or date? have any examples in the documentation? [message #55022 is a reply to message #55021] |
Mon, 05 October 2020 15:15 ![Go to previous message Go to previous message](theme/default/images/up.png) ![Go to next message Go to next message](theme/default/images/down.png) |
BetoValle
Messages: 203 Registered: September 2020 Location: Brasil Valinhos SP
|
Experienced Member |
|
|
(I didn't bother to change the name in the functions / classes of the whole prefix "int" but in reality I'm using it for "date")
see, these codes were made based on existing examples.
In the first case, curiously, a format function (inside another "format"
function of the inherited class) generates an exception (and should not).
In this situation, the content is "input date by the user", and the
setconvert was used as a filter so that in customizations,
it could evaluate the date entered. (is there a recursion occurring here ???)
Now in the second case it does not involve input by user, but it is the
same field where simply the same EditField (which uses setconvert)
cannot receive any date "with code". If you remove / disassociate the
setconvert from this editField, it will normally receive the date.
There are 2 problems! (see attached file / very simple example, with 1 field and 1 button/in the initial load of the program, the date is set to "dmy")
)
|
|
|
|
|
|
Goto Forum:
Current Time: Sun Sep 01 07:18:16 CEST 2024
Total time taken to generate the page: 0.03410 seconds
|
|
|