cristianotestai Posted February 11, 2016 Share Posted February 11, 2016 Hello, I'm trying to change a css (line-height) of a UniButton or apply a css class as below, but does not work. 1 UniButton1.ClientEvents.ExtEvents function OnAfterrender(sender){ var id = $(this).attr('id') + '-btnInnerEl'; $("#"+id).css('line-height', '15px'); } 2 Using UniSession.AddJSbegin UniSession.AddJS(UniButton1.JSName+'-btnInnerEl.addCls("x-line-height");');end; Any idea? Thanks. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted February 12, 2016 Share Posted February 12, 2016 Hi Cristiano, 1 UniButton1.ClientEvents.ExtEventsfunction OnAfterrender(sender){ var id = $(this).attr('id') + '-btnInnerEl'; $("#"+id).css('line-height', '15px'); } Try: function boxready(sender, width, height, eOpts) { sender.btnInnerEl.setStyle('line-height', '15px') } 2 Using UniSession.AddJSbegin UniSession.AddJS(UniButton1.JSName+'-btnInnerEl.addCls("x-line-height");');end; Any idea? Try: UniSession.AddJS(UniButton3.JSName + '.btnInnerEl.setStyle(''line-height'', ''15px'')'); Best regards Quote Link to comment Share on other sites More sharing options...
cristianotestai Posted February 14, 2016 Author Share Posted February 14, 2016 Thanks Delphi Developer! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.