PDA

View Full Version : [CLOSED] Set Panel Background Color



barnali
Feb 14, 2015, 10:55 PM
Hi,

Can you please guide me to set a background color of a panel. Not all panels, but just one specific panel.

Thanks.

geoffrey.mcgill
Feb 15, 2015, 5:00 AM
Hello,

Setting the .BodyCls property with the name of your css class should help.

http://docs.sencha.com/extjs/5.0/5.0.0-apidocs/#!/api/Ext.panel.Panel-cfg-bodyCls

RCN
Feb 15, 2015, 6:01 AM
21211



<!DOCTYPE html>
<html>
<head id="Head1" runat="server">
<style type="text/css">
.customPanel {
background-color: lightblue;
}
</style>
</head>
<body>
<ext:ResourceManager runat="server" />
<ext:Panel Title="Ext.Net" Html="Content" BodyCls="customPanel" Width="150" Height="150" runat="server" />
</body>
</html>

barnali
Feb 15, 2015, 7:01 AM
thanks. it worked.

RCN
Feb 15, 2015, 7:21 AM
Barnali, can this thread be marked as closed?