DhtmlxLayout - Enable scroll for div


Now we require to implement the Dhtmlx Layout which is used to display the dynamic data added to the table. I have one table which will be added with many trs and tds dynamically. Finally I have attach the table object into one of the layout cells. Here I could not achieve the auto scroller for div control even though I put overflow:auto property for that div.kindly help me to reslove this.



Example :In the below example, I have added tr and td to the table dynamically by clicking the button called Layout.

But I could not find scroll when data exedding the boundry of div.











Test-Layout














































































Try to call the following method after adding table rows:


dhxLayout.cells(“b”).dhxcont.mainCont.style.overflow=“auto”;


Alex.Thanks a lot.It is working excellent.



but here everytime i need scroll down to view latest item added to the table.I require to focus the scrollbar for bottom of the div.



Thanks  in advance.


You can try to use the following:


tdhxLayout.cells(“b”).dhxcont.mainCont.scrollTop = dhxLayout.cells(“b”).dhxcont.mainCont.scrollHeight;


Once again thanks a lot alex.



 



Perfect<?xml:namespace prefix = o ns = “urn:schemas-microsoft-com:office:office” /><o:p></o:p>

dhxLayout.cells(“b”).dhxcont.mainCont.style.overflow=“auto”;

It doesn’t seem to work in dhtmlx 4. How should I change it? Or is there a way to use “getElementById” on a layout cell?

Hello, Gonki
There is a method showInnerScroll() for it now:
docs.dhtmlx.com/api__link__dhtml … croll.html

I’m trying to disable horizontal scroll while leaving vertical in “auto”. Can this be done? With CSS maybe?

@Darya

May you please take a look at my question above?

You need

layout.cells("a").cell.style.overflowX = "hidden";

I’m not sure why it didn’t work…

And now? :slight_smile:

Yes, I meant it doesn’t work now:

B.cells(‘b’).cell.style.overflowX = “hidden”;

The cell contains a form and I tried this command before and after attaching the form. There is still a horizontal scrollbar.

Attach a demo, please
docs.dhtmlx.com/auxiliary_docs__ … pport.html