May 04, 2018, 8:02 AM
[CLOSED] Add Loader to a Panel Created Dynamically
Hi,
Well, basically what a want to do is create a panel dynamically and show an html on it. I have managed to do it on a static way, but i need to do it dynamically:
Here is an example:
Well, basically what a want to do is create a panel dynamically and show an html on it. I have managed to do it on a static way, but i need to do it dynamically:
Here is an example:
<%@ Page Title="Extranet Jhayber" Language="C#"
CodeBehind="Pruebaextnet.aspx.cs" Inherits="Extranet.Pruebaextnet" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
</head>
<body>
<ext:ResourceManager ID="ResourceManagerExt1" runat="server" IDMode="Explicit" />
<ext:Panel runat="server" id="panel1" Layout="ColumnLayout">
</ext:Panel>
<ext:Panel runat="server" id="panel2" Layout="ColumnLayout">
<items>
<ext:Panel runat="server" Header="false" ColumnWidth="0.333" Height="210" Frame="true">
<Loader runat="server" Mode="Frame" Url="../docs/360/85600-3-500.html">
<LoadMask ShowMask="true" MsgCls="loader" Msg="Cargando"/>
</Loader>
</ext:Panel>
</items>
</ext:Panel>
</body>
</html>
and here my cs file:public partial class Pruebaextnet : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
Ext.Net.Panel panelhtml = new Ext.Net.Panel();
panelhtml.ID = "panelhtml1";
panelhtml.ColumnWidth = 0.333;
panelhtml.Height = 210;
panelhtml.Frame = true;
panel1.Add(panelhtml);
/*Ext.Net.ComponentLoader html = new ComponentLoader();
html.Mode = LoadMode.Frame;
html.Url = "../docs/360/85600-3-500.html";
html.LoadContent();*/
/*panelhtml.Loader.Mode = LoadMode.Frame;
panelhtml.Loader.Url = "";
panelhtml.LoadContent();*/
}
As you can see there are 2 panels, panel2 is static and it works fine and its what I want to get in panel1 but in a dynamic way. I've tried to do it with the commented lines, but it has been impossible for me. Any solution?
Last edited by fabricio.murta; Jul 28, 2018 at 3:44 AM.