Home How to update Label caption when EditBox text change using LiveBindings in Delphi?
Reply: 0

How to update Label caption when EditBox text change using LiveBindings in Delphi?

user674
1#
user674 Published in May 26, 2018, 7:47 am

I can update the label caption when editbox text change if I use following code:

procedure TForm1.Edit1Change(Sender: TObject);
begin
    Label1.Caption:=Edit1.Text;
end;

If I do same with LiveBindings, It is only updating caption when I set focus on another control e.g. checkbox. I need to sync the label for each char I put in editbox. I used this

setting to bind.

I also tried following code but did not work for me: uses System.Bindings.helper;

procedure TForm1.Edit1Change(Sender: TObject);
begin
   TBindings.Notify(Sender, 'Text');
end;

Please help. Many Thanks.

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.299535 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO