Scroll container
Scroll container

Hello!
Is it possible to make container with table and scrollers flexible by user?
Because now it is static and user can't change it:
"scrollY": 400,
"scrollX": true,
This is problem for me, because users have different display size so table should also be able to be different sizes
Thank you
This discussion has been closed.
Replies
See if the solution in this blog does what you want.
Kevin
@kthorngren somehow it doesn't work. I am using both ScrollX and ScrollY
and when I use only ScrollY and comment ScrollX then table become
endless
Can you provide a link to your page or a test case replicating the problem so we can help debug?
https://datatables.net/manual/tech-notes/10
If you are trying to recreate the example with the element to drag the table size you will need to use the CSS and
div
from the page source as noted in the blog:Kevin
@kthorgren
I am trying to do resize here : http://live.datatables.net/geviguge/1/edit
on the table which you can see down on the right
I saw that I should use div container but there was nothing about how should I name it or which id should I give to it
Here is an example for the blog:
http://live.datatables.net/katenaga/1/edit
It has the resize_wrapper
div
and the resize_handlediv
plus the CSS for each. It has the event handler for the resize_handle. I addedscrollX
to show that works.Kevin
@kthorngren thank you very much! It works!
Do you know if it possible to make it flexible also i horizontal way?
Maybe I'm misunderstanding the question but if you enable scrollX the table size should automatically change size with the horizontal container size. You might be able to find techniques to dynamically size a container horizontally on Stack Overflow if thats what you are looking for.
Kevin
@kthorngren and maybe if it even possible you know, how to add some space after button "Click and drag me!" so there would be alwways more space to drag?