PDA

View Full Version : [CLOSED] How to add a HTML table to a Panel control dynamically



Fahd
Dec 20, 2012, 5:45 PM
Hi,
Can you please show me an example on how to insert a HTML table such as "<table></table>" to an ext.Panel control dynamically in the codebehind?

Many thanks for your help in advance!

Baidaly
Dec 21, 2012, 1:39 AM
Hello!

Try this one:



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

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

<script runat="server">
protected void Page_Load(object sender, EventArgs e)
{
HtmlTablePanel.Html = "<table><tr><td>Some table</td></tr></table>";
}
</script>

<!DOCTYPE html>

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

<ext:Panel runat="server" ID="HtmlTablePanel" Title="Panel with Html Table"></ext:Panel>
</form>
</body>
</html>

Fahd
Dec 21, 2012, 8:03 PM
Thank you! This will work for me.


Hello!

Try this one:



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

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

<script runat="server">
protected void Page_Load(object sender, EventArgs e)
{
HtmlTablePanel.Html = "<table><tr><td>Some table</td></tr></table>";
}
</script>

<!DOCTYPE html>

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

<ext:Panel runat="server" ID="HtmlTablePanel" Title="Panel with Html Table"></ext:Panel>
</form>
</body>
</html>