[Gambas-user] Stopping an event when user clicks on the form menu

Charlie Reinl Karl.Reinl at ...2345...
Fri Jan 24 00:44:16 CET 2014


Am Freitag, den 24.01.2014, 09:56 +1030 schrieb Bruce:
> I have a form with a textbox that "MUST" be filled in before moving on
> to the next control or any other control within the form. Fine, so I
> implement a txtManditory_LostFocus method that just checks that there is
> some text in there.
> 
> My problems are:
> 1) if the entire form loses focus, the lostfocus event fires.
> 2) if the user tries to click on the form menu the lost focus event
> fires.
> 
> I think I have got around 1) by using Object.Lock in a Form_Leave()
> handler, but 2) has got me stumped.
> 
> Any clues?
> 
> tia
> Bruce

Salut Bruce,

disable all others and set a 'continue' (enabled) behind .....
or let the user only enter to the form after filling that field in a
single form/field


-- 
Amicalement
Charlie





More information about the User mailing list