The Name Property

  • Thread starter Thread starter Jorge
  • Start date Start date
J

Jorge

Hi,
Can someone inform me as to why the Name property
does not always return the member name of the instance
variable? I often get a blank string as a value.

It would really help me if anyone could fill me in.

-J
 
Jorge,
Are these on dynamically created controls?

The Name property is what ever you set it.

The Windows Forms designer happens to set it to the name of the instance
variable while designing the form.

Think of the Name property as a freeform attribute (similar to the Tag
property) that you can set to any string you want.

Hope this helps
Jay
 

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

Back
Top