PDA

View Full Version : Share my pleasure with you.



jachnicky
Dec 26, 2008, 3:57 AM
hi,

guys,thanks to the coolite team.I am very happy that I can do something with coolite component.the attachement pic is my production,share my pleasure with everyone.:)

jchau
Dec 26, 2008, 9:38 AM
very cool. how did u get the purple theme to work?

jachnicky
Dec 26, 2008, 8:28 PM
ok,I show my job.

in Default.aspx,
html:


<ext:ComboBox ID="ddl_Theme" runat="server" Width="100px"
Editable="false"
ForceSelection="true">
<AjaxEvents>
<Select OnEvent="SetThemeSession"></Select>
</AjaxEvents>
<Listeners>
<Select Handler="ChangeTheme(#{CenterTabPanel},#{ddl_Theme});" />
</Listeners>
<Items>
<ext:ListItem Text="Default" Value="" />
<ext:ListItem Text="Slate" Value="ExtJS/resources/css/xtheme-slate.css" />
<ext:ListItem Text="Gray" Value="ExtJS/resources/css/xtheme-gray.css" />
<ext:ListItem Text="Black" Value="ExtJS/resources/css/xtheme-black.css" />
<ext:ListItem Text="Calista" Value="ExtJS/resources/css/xtheme-calista.css" />
<ext:ListItem Text="Chocolate" Value="ExtJS/resources/css/xtheme-chocolate.css" />
<ext:ListItem Text="Darkgray" Value="ExtJS/resources/css/xtheme-darkgray.css" />
<ext:ListItem Text="Green" Value="ExtJS/resources/css/xtheme-green.css" />
<ext:ListItem Text="Indigo" Value="ExtJS/resources/css/xtheme-indigo.css" />
<ext:ListItem Text="Midnight" Value="ExtJS/resources/css/xtheme-midnight.css" />
<ext:ListItem Text="Olive" Value="ExtJS/resources/css/xtheme-olive.css" />
<ext:ListItem Text="Peppermint" Value="ExtJS/resources/css/xtheme-peppermint.css" />
<ext:ListItem Text="Pink" Value="ExtJS/resources/css/xtheme-pink.css" />
<ext:ListItem Text="Purple" Value="ExtJS/resources/css/xtheme-purple.css" />
<ext:ListItem Text="Slickness" Value="ExtJS/resources/css/xtheme-slickness.css" />
</Items>
</ext:ComboBox>

client side script:


<script language="javascript">
var ChangeTheme=function(tabPanel,theme)
{
Coolite.Ext.setTheme(theme.getValue());
tabPanel.items.each(function(el) {
if(!Ext.isEmpty(el.iframe))
{
el.iframe.dom.contentwindow.Coolite.Ext.setTheme(t heme.getValue());
}
});
}
</script>

server side script:


// save the value to db.
protected void SetThemeSession(object sender,EventArgs e)
{
OATheme.SetTheme(this, ddl_Theme.SelectedItem.Value);
}

//and initiate the theme
protected void Page_Load(object sender, EventArgs e)
{
string myTheme = OATheme.GetTheme(this);
for (int i = 0; i < ddl_Theme.Items.Count; i++)
{
if (ddl_Theme.Items[i].Value == myTheme)
{
ddl_Theme.SetValueAndFireSelect(myTheme);
break;
}
}
}


in others pages' page_load method:



protected void Page_Load(object sender, EventArgs e)
{
//select the theme from db and set the page's theme.
OATheme.GetTheme(this);
}


hope this helps

aswad32
Dec 30, 2008, 6:04 AM
 here's mine, some prototype i produce to convince my boss about coolite, i used ADO.NET entity framework for data layer, i feel great to produce s'thing like this hahaha.... man, coolite rocks.

jachnicky
Dec 30, 2008, 8:12 PM
hi,

guys,I can't open the attachments,why?i click the attachments then redirect to the http://forums.ext.net/.

leflaco
Mar 05, 2009, 2:43 PM
Hi, i have the same issue. Anyone can help us?

Vladimir
Mar 05, 2009, 2:54 PM
Please ensure that you logged in when try to open attachments

leflaco
Mar 05, 2009, 2:58 PM
thanks vladimir, that was the problem.

geoffrey.mcgill
Mar 05, 2009, 3:22 PM
@aswad32 - Thanks for sharing your screen captures... your app looks great. Nice job!

bruce
Mar 06, 2009, 10:18 PM
Hello ,jachnicky !

Are you Chinese? hehe, me too. Could you send something about your project to me? I want to study your good project! Thank you very much!

This is my email: coolcode@live.com
and my blog in China: http://blog.csdn.net/fengart

Bruce

fabiomarcos
Aug 11, 2009, 12:05 PM
Hi jachnicky,

I was studying your project, but I could not find what OATheme object is. Itīs not defined. Is it a scriptManager ?
Could you please help me ?

Thanks