Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Inheriting from an MDIParent Form
Message
From
09/09/2006 22:31:55
 
 
To
09/09/2006 18:07:21
General information
Forum:
ASP.NET
Category:
Forms
Miscellaneous
Thread ID:
01150477
Message ID:
01152615
Views:
21
Hi!

Thanks for the investigation. I will have a look at the links.

Oh one more thing have you implemented cut-copy-paste on the toolstrip or in the menu? I am having problems trying the figure out the active control when I click on the toolstrip. eg. If the user is in the 3rd row of the 2nd column in a DataGridView which is on a usercontrol which is on a MDI Child form (in an MDI Parent form) the ActiveControl does not give the correct information. How should I go about implementing this cut-copy-paste feature generically (meaning this should work for any contol (no matter how deep it is) on any MDI Child form)

Thanks again.

Sarosh


>Sarosh,
>
>I can't find much info on this problem. I *still* think it's a bug, but no one from Microsoft has replied to a thread I started on the MSDN forums ... here's a link to it:
>
>http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=693915&SiteID=1
>
>[UPDATE]: I've just discovered a pretty cool MSDN Wiki and it seems that it says a little more than the docs do about ToolStrip. Here's a link:
>
>http://msdnwiki.microsoft.com/en-us/mtpswiki/system.windows.forms.toolstrip(VS.80).aspx
>
>One of the things it mentions is:
>
>>Use ToolStripPanel rather than ToolStripContainer for Multiple Document Interface (MDI) applications.
>
>I don't know if this applies to you or not, but you *did* mention that you were using an MDI form.
>
>~~Bonnie
>
>
>
>>Hi!
>>
>>Thanks I will be waiting for your reply.
>>
>>Sarosh
>>
>>>Sarosh,
>>>
>>>The ToolStrip seems to work totally different than the old ToolBar did. In our app we don't use MDI forms, but I don't think it matters as far as your question is concerned.
>>>
>>>What we have used for our ToolBar base class is basically a UserControl with a ToolBar control on it. This is very easily sub-classed and *all* the ToolBar properties are still available visually to add buttons to, etc. Not so with the ToolStrip ... as you've mentioned, I also found that *NONE* of the properties are available in the sub-class. I've been playing with it a bit this morning trying to get the same functionality out of the ToolStrip as I have with the ToolBar and I'm not having any luck.
>>>
>>>I'm still looking into this further and I'll get back to you with any results I can dig up.
>>>
>>>~~Bonnie
>>>
>>>
>>>
>>>>Hi!
>>>>
>>>>Yes the property sheet is greyed out (disabled/readonly). This is an MDI Parent Form with a MenuStrip, ToolStrip, BindingNavigator, StatusStrip etc. and it would be much easier to viusally add options to the menustrip and buttons to the toolstrip than by code.
>>>>
>>>>Is this a know bug/proglem? If it is then it is pretty serious one and hopefully should be fixed ASAP.
>>>>
>>>>Thanks
>>>>
>>>>Sarosh
>>>>
>>>>>Sarosh,
>>>>>
>>>>>I assume the problem is that you can't access your components from the Property Sheet? You'd see, if you tried to access them in code, that everything would work fine.
>>>>>
>>>>>Try this: anything that needs to be accessible from the Property Sheet, make them actual *properties* (with get/set methods). That should help.
>>>>>
>>>>>~~Bonnie
>>>>>
>>>>>
>>>>>
>>>>>>Hi!
>>>>>>
>>>>>>All the components have their access modifier property set to Public also tried all the other possible options but no luck.
>>>>>>
>>>>>>Sarosh
>>>>>>
>>>>>>>Take a look at the access modifier property of your main form. It is probably set to private. In order for those fields to be available in a sub-class, I think you need to set it to protected or public.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>>Hi!
>>>>>>>>
>>>>>>>>When I inherit an MDI Parent Form from a DLL (another project of mine like a base class library) all its components (Menu, Toolbar, BindingNavigator etc) become readonly not sure why?
>>>>>>>>
>>>>>>>>What am I doing wrong here.
>>>>>>>>
>>>>>>>>Sarosh
Previous
Reply
Map
View

Click here to load this message in the networking platform