Dhtmlxdataview output window size?

Hello ,

I’m trying to build a dhtmdataview output inside of a tab. It works however I’m getting it in a small box … how can I set automatically that dataview object must be the same size like tab window?

thanks
Igor

Hello,

Try to use attachDataView method to place dataview in a tab:

data = tabbar.cells(“tab1”).attachDataView({

});

Please have a look at the similar sample:

dhtmlxDataView/samples/08_integration/04_layout.html

Hello,

Thanks for the feedback.
I understand how to attach the DataView to the tab and that works just fine , the issue is that
without setting manually height and width the dataview output is limited to a small cell in which all text is wrapped :frowning: I tried to set height and width to 100% in template but after that dataview is not displayed at all … so my question is how can I adjust dataview output size to the size of the tab to which it is attached …?

Thanks
Igor

P.S. I could not find example that you are referring to … I have “07_dhtmlxfolders”
as the last one in the examples folder

Hello Igor,

height and width of dataview items can be defined in type property:

{

type:{
height: 80,
width: 120,

}
}

Hello Alexandra,

Well, this will be defining static size of the dhtmlxdataview object … what if size of the TAB window will be changed ? How can I make that dhtmlxdataview object size will be equal to the size of the TAB?

Thanks
igor

Hello,

the size of dataview items are fixed. If Dataview is initialized using attachDataview metod, the size of its div is adjusted to tab size. But note that size of dataview items won’t be changed.

Hello Alexandra,

Thanks a lot for the clarification, so since DataView is a static object size wise Is there a different way than DataView to build an HTML based template based on the received data from MySQL and display it a tab? Can I do it without DataView object?

Thanks
Igor

P.S. Sorry i forgot to ask … according to your feedback " If Dataview is initialized using attachDataview metod, the size of its div is adjusted to tab size." I Use exactly this method to attach it it to the tab however it it does not create div size equal to tab. If I don’t explicitly specify size of the dataview template I get what is on the picture … If I set explicetly then there is no chance that I can match exactly the tab size since it can be different on different
systems/screens … Please explain …

Thanks
Igor

We need the complete demo to reproduce the problem:

docs.dhtmlx.com/doku.php?id=othe … leted_demo

Hello Alexandra,

It took me a bit a while to come back to you with the example however please find attached requested example code. Like I explained before it appears that initialized dataview object does not adjust the size of its div to tab size.

Regards
Igor
Broken_dhtmlxDataView.tar.gz (405 KB)

Hi,

there is only one item in your dataview. And as you are using default item sizes (210 x 115) the item is displayed this way. So, everything is correct.

Dataview items have fixes size. They height and width can be defined in type property.