Hey, thanks for your answer!
"yourEntity" is an instance, isn't it?
using this:
this.TextBox1.DataBindings.Add(new Binding("Text", bsContent, "TxtNote", true));
The DataSource parameter is a constant.
if i use something like
this.TextBox1.DataBindings.Add(new Binding("Maxlength", bsContent, "constant??", true));
i should be able to use a constant value too?
Because:
if i used a value coming from the "myEntity" instance, the code would fail (null exception), if there is no instance. This is the case when there is an empty collection i want to add a new entity with bound controls. Then there is no initial entity,whose maxlength property i could use.
Is there no other way to get maxlength? In my understanding maxlength should be a static property of the entitytype, or do I miss something?