[Logo] OLD FORUM - Use new one: https://www.CaptainCasa.online/forum
  [Search] Search   [Recent Topics] Recent Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Button enabled/disable without server roundtrip  XML
Forum Index -> Development
Author Message
bthalheim

Power User

Joined: 05/04/2012 11:45:24
Messages: 72
Offline

Hi,

I implemented the following:
Given a Popup with Text Area and OK button.
The OK Button is enabled if the text bound to the text area in the UI class is non-empty.
The text area is done with flush and flushtimer=3sec.

This works. But I don't like it. The problem is that if you choose your flushtimer too short, typing in your text area is no fun! If you choose it to long, you'll have to wait for too long of a time after hitting the last key until the Button becomes enabled (of course you could just cause a server roundtrip by moving the focus out of the text area).

Is the logic described above possible without a client roundtrip (basically, I would do all simple synchronous validiation like in the example in the client)?

Thanks,

Björn
CaptainCasa

Power User
[Avatar]

Joined: 21/11/2007 12:23:06
Messages: 5555
Offline

Hi,

no this is not possible without roundtrip.

Alternative would be: set TEXTAREA-BGPAINT to "mandatory()" so the user sees that this is an obligatory input. Then of course the Button always would be enabled, but the user see much better what is expected.

Regards, Björn

Björn Müller, CaptainCasa GmbH
bthalheim

Power User

Joined: 05/04/2012 11:45:24
Messages: 72
Offline

OK, so I'll work with Backgroundpane and Statusbar to indicate this kind of situation and so this kind of validation in an asynchronous style.

Thanks,

Björn
 
Forum Index -> Development
Go to:   
Powered by JForum 2.1.6 © JForum Team