M
M
MainNika2010-11-13 00:17:05
Delphi
MainNika, 2010-11-13 00:17:05

Delphi (Lazarus) - dynamic objects, and their events?

Good day, Delphi gurus and not only. The case is this: The procedure is
described
procedure tform1.onbclick(Sender: TObject);
. I create a bunch of Buttons in an array during the program execution, and assign this procedure to them as an OnClick event.
ArBut[i][email protected];
Everything works, except for the Sender parameter. How should it be correctly specified in this case? Or how can I get around it?
upd:
Everything works. I mixed up the name and caption parameters in the onbclick procedure. but I didn’t specify the name during dynamic creation, so his request was empty and I thought that nothing was working.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
H
Horse, 2010-11-13
@MainNika

ArBut[i][email protected];

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question