Mortymer Posted August 3, 2013 Share Posted August 3, 2013 Hello All, How can I set tabposition in Pagecontrol component. I found this lines in javascript code: OE3 = new Ext.Panel({ id: "OE3_id", layout: "anchor", baseCls: "", width: 495, height: 213, x: 224, y: 122 }); OE3.nm = "OE3"; _cdo_("GPWebPageControl1", OE3, null, MainForm); OF2 = new Ext.TabPanel({ plain: true, anchor: "100% 100%", enableTabScroll: true, deferredRender: false, layout: "absolute", id: "OF2_id", activeTab: 0 }); OF2.nm = "OF2"; OF2.on("tabchange", function(P0, P1) { return Ext.Ajax.request({ url: "/HandleEvent", params: "Ajax=1&IsEvent=1&Obj=OF2&Evt=tabchange&This=" + P0.nm + "&Tab=" + P1.nm + "" + _gv_(O10), success: AjaxSuccess, failure: AjaxFailure, obj: OF2, How can I insert "tabPosition: 'left'," this codeline into Ext.TabPanel definition section. Thank you for any help or answer! Mortymer Link to comment Share on other sites More sharing options...
mhmda Posted August 3, 2013 Share Posted August 3, 2013 Hi, You may try this: (all client side code - js) Project from here: http://www.3msoft.net/mhmd/Tabs.rar function OnClick(sender, e) { //switch position var tab1=MainForm.UniPageControl1.items.getAt(0).items.getAt(0); MainForm.UniPageControl1.items.getAt(0).items.getAt(0).tab.hide(); MainForm.UniPageControl1.items.getAt(0).insert(2,tab1); } If you wish to add icons to tab's title like this: You could use this code: MainForm.UnipageControl1.items.getAt(0).items.getAt(0).setIconCls('stngs_icon'); and the css is: .stngs_icon{ background-image: url("images/stngs.png") !important; } I hope this help you... 1 Link to comment Share on other sites More sharing options...
Mortymer Posted August 3, 2013 Author Share Posted August 3, 2013 Thank you mohammad I try this solution Hi, You may try this: (all client side code - js) Project from here: http://www.3msoft.net/mhmd/Tabs.rar function OnClick(sender, e) { //switch position var tab1=MainForm.UniPageControl1.items.getAt(0).items.getAt(0); MainForm.UniPageControl1.items.getAt(0).items.getAt(0).tab.hide(); MainForm.UniPageControl1.items.getAt(0).insert(2,tab1); } If you wish to add icons to tab's title like this: You could use this code: MainForm.UnipageControl1.items.getAt(0).items.getAt(0).setIconCls('stngs_icon'); and the css is: .stngs_icon{ background-image: url("images/stngs.png") !important; } I hope this help you... Link to comment Share on other sites More sharing options...
Semper Posted August 4, 2013 Share Posted August 4, 2013 mohammad, It helps me too. Thanks! Link to comment Share on other sites More sharing options...
gpaulino Posted August 9, 2013 Share Posted August 9, 2013 hi i am trying to add icons to tabs but I can not visualize anything???? help????? Link to comment Share on other sites More sharing options...
mhmda Posted August 11, 2013 Share Posted August 11, 2013 1. put the icon file in the dirsctory (you can find here any icon you want: http://www.findicons.com) 2. add the css code to ServerModule-->CustomeCSS: .stngs_icon{ background-image: url("images/stngs.png") !important; } Important: the url directory depending on your settings in the servermodule->FilesFolder if you didn't make any changes to "FilesFolder" then use this in the url: "files/images/stngs.png" 3. Set the icon at run time: function OnAfterrender(sender) { var obj=MainForm.UniPageControl1.items.getAt(0).items.getAt(0); obj.setIconCls('stngs_icon'); } Project from here: http://www.3msoft.net/mhmd/tabs_icon.rar Online from here: http://79.143.180.27/animateform/animateform.dll Hope this will help you 1 Link to comment Share on other sites More sharing options...
gpaulino Posted August 12, 2013 Share Posted August 12, 2013 hi guys for I put icons on the tab only slightly change the way in the event of unipageControl1 onbeforerender place the following code only modify the premium for one hope that works. sender.items.getAt (0). items.getAt (0). setIconCls ('stngs_icon'); Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now