[Lazarus] Buttons in frames

Mark Morgan Lloyd markMLl.lazarus at telemetry.co.uk
Thu Jan 31 11:00:31 CET 2013

Mattias Gaertner wrote:
> On Wed, 30 Jan 2013 14:06:49 +0000
> Mark Morgan Lloyd <markMLl.lazarus at telemetry.co.uk> wrote:
>> I've got a form which I'm creating manually before a program's main 
>> form, in order to read configuration settings which are needed early. 
>> The form contains a notebook, and I've implemented forward/backward 
>> buttons to give a wizard-like interface. It's also got a modal cancel 
>> button to prevent the app from starting. That combination's working fine.
>> I've moved the notebook and its contents into a frame, made sure that 
>> the events are hooked up, and dropped the frame onto a clean form.
>> When the program runs, the form is created and displayed and the modal 
>> cancel button works, but none of the other events fire in response to 
>> user actions. This is with Lazarus trunk + 2.6.0.
>> I've just written a trivial program with a frame and button on the main 
>> form and events appear OK, so it appears to be something to do with 
>> early-creation of the form and content. Unless anybody can point out 
>> what stupid mistake I'm making I'll extend my test program with an 
>> early-created form and raise a bug if the problem persists.
> It should work.
> Can you create a small example to demonstrate the problem?

I can't duplicate it with a newly-created test program. However I notice 
that this program has  implementation ... {$R *.lfm}  in (at least) 
those units with forms, while the program giving the problem doesn't. 
Any thoughts would be appreciated before I wade in trying to "fix" things.

Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]

More information about the Lazarus mailing list