neseir Posted May 18, 2018 Share Posted May 18, 2018 Hi How can I get the table layout to change number of columns runtime ? Setting the layoutAttribs.Columns to a different number does not update the rendering (set to 2 columns at designtime and changed to 4 runtime keep adding components as it still is 2). Not sure if invalidating and refresh is meant to be used but they did not do any difference. BR Eirik Quote Link to comment Share on other sites More sharing options...
Sherzod Posted May 18, 2018 Share Posted May 18, 2018 Hi, One possible solution, for example for UniContainerPanel1: procedure TMainForm.UniButton1Click(Sender: TObject); begin with UniContainerPanel1 do begin LayoutAttribs.Columns := 4; JSInterface.JSCall('setLayout', [JSControl.JSObject('type:"table", columns:'+IntToStr(LayoutAttribs.Columns))]); end; end; Best regards, Quote Link to comment Share on other sites More sharing options...
neseir Posted May 18, 2018 Author Share Posted May 18, 2018 Thanks ! That worked perfect. Will check the actual page to see the how this is processed but in function this solved it. BR Eirik 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.