Windows Develop Bookmark and Share   
 index > Windows Forms Designer > problems with modifying name property
 

problems with modifying name property

Hello there, 7 Ţurţuri is back with more disturbing questions!!!

I am currently modifying my designer to allow control renaming. But what do you know? I have problems here also !
I've implemented the IExtenderListService and got the (Name) property in my grid. When I rename a component, the new name is verified and I do get a message telling me that the new name is not allowed. That's okay... for now. Because when I rename it corectly, i get an "Object reference not set to an instance of an object" name for my control. Then I try to debug it and see if there are any exception unhandled. None. And when I resume from debug, I get the correct name for the control. :-? A friend told me it maybe because there is a thread sync problem around there. Plausible.

So, designer gurus ^:)^ ! What should I do?
7 Å¢urÅ£uri  Friday, April 03, 2009 12:17 PM
Hi,

What's the error shows when the new name is not allowed?

Best regards,
Ling Wang
Please remember to click “Mark as Answer�on the post that helps you, and to click “Unmark as Answer�if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
Ling Wang  Thursday, April 09, 2009 10:00 AM
Hi, Ling Wang

I do not get an exception that may be caught or anything like that. The (Name) property of the newly renamed control shows the following string, no matter which control I rename : "Object reference not set to an instance of an object." Do you have any hint as to why does this happen?
7 Å¢urÅ£uri  Thursday, April 09, 2009 1:25 PM
->Object reference not set to an instance of an object.

This error always happen a object or control has definitionbut you don'tinitialize it.
Please remember to click “Mark as Answer�on the post that helps you, and to click “Unmark as Answer�if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
Ling Wang  Thursday, April 09, 2009 1:28 PM
->This error always happen a object or control has definitionbut you don'tinitialize it.

It cannot be uninitialized. Remember I am only renaming it, not removing it and adding a new control with the new name.
7 Å¢urÅ£uri  Thursday, April 09, 2009 1:42 PM

You can use google to search for other answers

Custom Search

More Threads

• bug: "could not load type"
• Designer Keeps Resizing Controls On Build
• how can we have Image and corresponding text in ListBox
• Why is button not showing with rounded edges?
• TableLayoutPanel troubles -- adding runtime controls
• Problem with Usercontrol
• Windows Forms
• finding the position of labels in the propertygrid
• In the form designer I can't access objects which are on an other form.
• ListView GridLines