DHTMLX Docs & Samples Explorer

setSizes()

Required library edition: This method works with any edition of DHTMLX library
Required library file: dhtmlxaccordion.js

changes object instance's size according to the outer container

For example, in case we have an object on the page, which will be used as accordion parent container:

<div id="myAcc" style="width: 300px; height: 500px;"> </div>

Initializing accordion:

var dhxAcc = new dhtmlXAccordionObject("myAcc");

Changing parent container's dimension:

var parentObj = document.getElementById("myAcc");
parentObj.style.width = "250px";
parentObj.style.height = "400px";

Adjusting accordion:

dhxAcc.setSizes();