Databinding problem with inherited class

O

Olivier Deborne

Hello,

I have two classes A & B

public class A : B
{
private string lastname;

public string LastName
{
get{};
}
}

public class B
{
private string firstname;

public string FirstName
{
get{};
}
}

Class A inherits from B. When I try to databind the field FirstName, an
error occurs

MyTextBox.DataBindings.Add("Text", A, "FirstName"). It seems the databinding
does not see the property "FirstName", what I'm doing wrong?

Thanks for your help.

BRgds,
Olivier.
 
T

Tpool

hi nair,

i raised one question in the same group, with subject title"threads". help
me please.

thanks
Tpool
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top