Aug 28, 2012, 8:32 AM
[CLOSED] Disabled Style applied incorrectly
Hi,
I created a test case with the error that I reproduce in my MVC project.
When you have it loaded, press buttons 3 and 4 or 4 and 3 to enable tabpanel and formpanel and you'll see controls are enable (you can write and click it) but css style looks like if the control is disabled.
SAMPLE PAGE
I created a test case with the error that I reproduce in my MVC project.
When you have it loaded, press buttons 3 and 4 or 4 and 3 to enable tabpanel and formpanel and you'll see controls are enable (you can write and click it) but css style looks like if the control is disabled.
SAMPLE PAGE
<!DOCTYPE html>
<html>
<head runat="server">
<title>Ext.NET Example</title>
</head>
<body>
<form runat="server">
<ext:ResourceManager runat="server" />
<ext:Panel runat="server" Layout="HBoxLayout">
<Items>
<ext:Button runat="server" Text="1-Disable Form">
<Listeners>
<Click Handler="myForm.setDisabled(true);" />
</Listeners>
</ext:Button>
<ext:Button runat="server" Text="2-Disable Tab">
<Listeners>
<Click Handler="myTab.setDisabled(true);" />
</Listeners>
</ext:Button>
<ext:Button runat="server" Text="3-Enable Form">
<Listeners>
<Click Handler="myForm.setDisabled(false);" />
</Listeners>
</ext:Button>
<ext:Button runat="server" Text="4-Enable Tab">
<Listeners>
<Click Handler="myTab.setDisabled(false);" />
</Listeners>
</ext:Button>
</Items>
</ext:Panel>
<ext:FormPanel ID="myForm" runat="server">
<Items>
<ext:TabPanel ID="myTab" runat="server">
<Items>
<ext:Panel ID="MyPanel" runat="server" Layout="FitLayout" Title="Panel with partial view" Height="500">
<Loader runat="server" Url="/Area/Sample/MyPartialView" Mode="Script" TriggerEvent="activate">
<LoadMask ShowMask="true" Msg="Custom loading message..." UseMsg="true" />
<Params>
<ext:Parameter Name="containerId" Value="#{MyPanel}" Mode="Value" />
<ext:Parameter Name="dummy" Value="(new Date()).getTime()" Mode="Raw" />
</Params>
</Loader>
<Listeners>
<BeforeRender Handler="myForm.setDisabled(true);myTab.setDisabled(true);" />
</Listeners>
</ext:Panel>
<ext:Panel ID="MyPanel2" runat="server" Layout="FitLayout" Title="Panel with partial view 2" Height="500">
<Loader runat="server" Url="/Area/Sample/MyPartialView" Mode="Script" TriggerEvent="activate">
<LoadMask ShowMask="true" Msg="Custom loading message..." UseMsg="true" />
<Params>
<ext:Parameter Name="containerId" Value="#{MyPanel2}" Mode="Value" />
<ext:Parameter Name="dummy" Value="(new Date()).getTime()" Mode="Raw" />
</Params>
</Loader>
</ext:Panel>
</Items>
</ext:TabPanel>
</Items>
</ext:FormPanel>
</form>
</body>
</html>
PARTIAL VIEW CONTENT<ext:Panel runat="server">
<Items>
<ext:TextField runat="server" />
<ext:ComboBox runat="server">
<Items>
<ext:ListItem Text="Item" Value="1" />
</Items>
</ext:ComboBox>
</Items>
</ext:Panel>
CONTROLLER TO LOAD PARTIAL VIEWpublic ActionResult MyPartialView(string containerId)
{
Ext.Net.MVC.PartialViewResult r = new Ext.Net.MVC.PartialViewResult(containerId, Ext.Net.RenderMode.AddTo);
r.SingleControl = true;
r.WrapByScriptTag = false;
return r;
}
Last edited by Daniil; Sep 21, 2012 at 10:54 AM.
Reason: [CLOSED]