PDA

View Full Version : [CLOSED] Trouble with modal mode



tMp
Jan 02, 2014, 3:06 PM
Hi

I am sorry for not having a working example yet for this problem - I just can't really isolate it so I hope that perhaps anyone can lead me on the right track. In the meantime I have to strip down my application to get the problem isolated.

What I have:
A am creating a window in code behind that has several tabpanels and in the last of them are 3 gridpanels (one with a command column). this window is created by a direct method and is shown using modal = true.

The Problem:
When I just show the window and close it again. The modal mode stays on and I can do anything with the website under it. If I click on the last panel to see the 3 gridpanels and then close the window everything is working fine. Until now I could isolate it to the command column in the third gridpanel. As soon as I comment it out everything works alright. I already tried to make a single example but so far everything in that one is working too. It has to be a very special setting.

Any help or tips? I will post a working "non-working" example as soon as I can strip the whole app down.

thank you very much and best regards.

geoffrey.mcgill
Jan 02, 2014, 8:37 PM
The modal mode stays on and I can do anything with the website under it.

I'm not sure I completely understand the situation here, but are you saying the Window closes, but the full page mask is not removed? and you are able to modify elements under the mask?

A sample demonstrating how to reproduce will certainly help narrow down the problem.

If you run the app with Firefox + Firebug, are there any JavaScript errors or exceptions being thrown during this process?

tMp
Jan 03, 2014, 3:33 PM
Hi Geoffrey,

Sorry, there was a typo in the sentence. The full page mask is not removed and I can't modify any elements under the mask. So the user has to reload the whole page again to go on...

I know, I am working on an example to show it but I have to strip the whole application down because when I try to reproduce it from bottom up I don't get that error. I will also have a look what firebug means, when I run it. Will report back asap...

Daniil
Jan 06, 2014, 11:17 AM
I know, I am working on an example to show it but I have to strip the whole application down because when I try to reproduce it from bottom up I don't get that error.

Yes, sometimes it is difficult to create a sample. If you can share access to your application online, it might help us to understand the problem. This way you might avoid the work on a sample. Though, sometimes online samples don't help us to understand the problem. In this case we will still request a simple sample to be posted here.

tMp
Jan 11, 2014, 7:02 AM
Please don't close this issue yet. I am still trying to narrow down the error for an example. Unfortunately it is a core application and I have to strip it down completly.

Thank you!

tMp
Jan 15, 2014, 5:03 PM

Daniil
Jan 16, 2014, 3:40 AM
There is a JavaScript error.

TypeError: this.grid is undefined

I think the mask is not hidden because of that error.

The error occurs due to a bug in Ext.NET. We are investigating. Here is a simplified test case.

The key points:

1. A GridPanel has a CommandColumn or a ComponentColumn.
2. Call a GridPanel's destroy when a GridPanel is not rendered yet.

Example

<%@ Page Language="C#" %>

<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>

<!DOCTYPE html>

<html>
<head runat="server">
<title>Ext.NET v2 Example</title>
</head>
<body>
<form runat="server">
<ext:ResourceManager runat="server" />

<ext:Button runat="server" Text="Destroy" Handler="App.GridPanel1.destroy();" />

<ext:TabPanel runat="server">
<Items>
<ext:Panel runat="server" Title="Tab 1" />

<ext:GridPanel ID="GridPanel1" runat="server" Title="Tab 2">
<Store>
<ext:Store runat="server">
<Model>
<ext:Model runat="server">
<Fields>
<ext:ModelField Name="test" />
</Fields>
</ext:Model>
</Model>
</ext:Store>
</Store>
<ColumnModel runat="server">
<Columns>
<ext:Column runat="server" Text="Test" DataIndex="test" />
<ext:CommandColumn runat="server" />
<ext:ComponentColumn runat="server" />
</Columns>
</ColumnModel>
</ext:GridPanel>
</Items>
</ext:TabPanel>
</form>
</body>
</html>

Daniil
Jan 16, 2014, 4:19 AM
Fixed in the SVN trunk, revision #5606. It will go to the v2.5 release.

Thank you for the test case!

tMp
Jan 16, 2014, 7:41 AM
Thank you for the solution and sorry again for the long time it took me to deliver a working example.

best regards.

Daniil
Jan 16, 2014, 12:06 PM
No problem. Sorry for the bugs in Ext.NET:)