It is possible to do something like XE2 LiveBindings in D2010?
Asked Answered
S

2

4

It's factible or it uses some compiler technology only available in XE2 ?

I just want to bind (bidirectional) a TEdit.Text property to a object function that returns a string in code (I don't need designer components or expression evaluators)..

Thanks!

Solstice answered 24/10, 2011 at 22:12 Comment(2)
Check this article of Stefan Glienke delphisorcery.blogspot.com/2011/04/data-bindings-revisited.html you can download the sample and the binding library from here delphisorcery.googlecode.com/files/DataBindingSample.zipDefroster
I recommend to use the latest revision from the svn since the zip archives are very old and outdated. There is also currently a problem in Delphi 2010 which is related to some in XE fixed bug in the Rtti.pas which causes an EInvalidCast exception but I am working on it.Yorgos
B
11

I guess you could try Delphi sorcery library. It has quite powerful data binding solution which should work in all the modern Delphi versions.

Belda answered 24/10, 2011 at 22:35 Comment(0)
A
2

No, as far as I can tell, the LiveBindings system was implemented entirely in code with no new language features introduced to support it. Which is a bit of a shame, IMO; it could be a much simpler and overall better system if the language had support for something like property references.

Aramen answered 24/10, 2011 at 22:34 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.