﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » WinForms (How do I?)  » Disable themed link menu on main form from editingstatechanged of MDI child?</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Tue, 08 Sep 2026 18:34:29 GMT</lastBuildDate><ttl>20</ttl><item><title>Disable themed link menu on main form from editingstatechanged of MDI child?</title><link>http://forum.strataframe.net/FindPost30925.aspx</link><description>I a themed link menu that opens MDI children on the main form.&amp;nbsp; Inside a child form I can see a ParentForm reference to the frmMainForm but I can't see a reference to the ThemedLinkMenu ( tlmAction ) so I can set it as enabled = false.&lt;br/&gt;&lt;br/&gt;The request from the client is to not allow opening another form while the current form is editing and this seemed the most straightforward way to accomplish this though I'm open to other suggestions.&amp;nbsp; &lt;br/&gt;&lt;br/&gt;I planed to see the tlmAction.Enbled = false in my EditStateChanged of each form.&lt;br/&gt;&lt;br/&gt;Tried a public property in frmMainForm which was a reference to the TLM&lt;br/&gt;&lt;br/&gt;&lt;pre style="font-family:Consolas;font-size:13;color:black;background:white;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:blue;"&gt;public&lt;/span&gt;&amp;nbsp;MicroFour.StrataFrame.UI.Windows.Forms.&lt;span style="color:#2b91af;"&gt;ThemedLinkMenu&lt;/span&gt;&amp;nbsp;tlm&amp;nbsp;{&amp;nbsp;&lt;span style="color:blue;"&gt;get&lt;/span&gt;;&amp;nbsp;&lt;span style="color:blue;"&gt;set&lt;/span&gt;;&amp;nbsp;}&lt;br/&gt;(then inside constructor ) &lt;br/&gt;&lt;br/&gt;       tlm = this.tlmAction ;&lt;br/&gt;&lt;br/&gt;But I see no ref to this property when looking at ParentForm inside my other forms.&lt;br/&gt;&lt;br/&gt;Thought about trying to cancel in the leave of the form but can't find anything in the args to do that.  Suggestions for a form-event approach?&lt;br/&gt;&lt;br/&gt;either disabling the TLM or preventing leaving the form until there is an undo or save would work for me.&lt;br/&gt;&lt;br/&gt;Seems there is a more elegant way to accomplish this but I can't wrap my head around it.  &lt;br/&gt;&lt;br/&gt;Thanks in advance&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;/pre&gt;</description><pubDate>Tue, 14 Feb 2012 16:56:00 GMT</pubDate><dc:creator>Charles R Hankey</dc:creator></item><item><title>RE: Disable themed link menu on main form from editingstatechanged of MDI child?</title><link>http://forum.strataframe.net/FindPost30926.aspx</link><description>Hi Charles,&lt;br/&gt;&lt;br/&gt;The StrataFlix sample uses an approach that will allow you to do just that.&amp;nbsp; The TLM uses Action Link Menu Items, so in your base form class you would have a property as New ActionLinkMenuItemCollection which is a class in the StrataFlix project to hold all the action menu items.&amp;nbsp; There are more code to Enable/Disable items.&lt;br/&gt;&lt;br/&gt;In your case if you have a parent form with the TML and a child form which is not a Dialog Form, then you would either add code to your child form to see if an instance already exist and just use that instance instead of opening a new one.</description><pubDate>Tue, 14 Feb 2012 16:56:00 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item></channel></rss>