Is there a way to turn off that second scrollbar in the dgid? The one furthest to the right. It seems to have no use and creates an unwanted margin.
I found lots that can be done with the dgrid in css but nothing on this large scrollbar.
Solved! Go to Solution.
Robert,
Got it! Thanks, I'm a bit new at some of these things. Using Chrome's dev tools, found that this is how one turns off overflow scrollbar:
.dijitContentPane { overflow: hidden: }
However, this turns off all the overflow scrollbars on all ContentPanes, some I do not want turned off (but this is still good to know in the future).
So I just added an inline css to the ContentPane holding my dgrid and works great.
<div data-dojo-id="bottomGridPane" data-dojo-type="dijit/layout/ContentPane" data-dojo-props="splitter:'true', region:'bottom'" style="height: 240px; overflow: hidden;"> <div id="divGridActivities"></div> </div>
Thanks so much for your help, much appreciated.
David,
you need to set the css overflow on the grids parent div to be hidden.
OK, this does not seem to work for me. Exactly what do I need to do in my code?
This is the div that holds my dgrid:
<div id="divGridActivities"></div>
This is the css for that div:
#divGridActivities { overflow: hidden; }
David,
That looks correct to me. Is it the divGridActivities parent that is getting the scrollbar? Normally I determine this by using my browser developer tools to inspect the html elements and messing around with changing css at runtime.
Robert,
Got it! Thanks, I'm a bit new at some of these things. Using Chrome's dev tools, found that this is how one turns off overflow scrollbar:
.dijitContentPane { overflow: hidden: }
However, this turns off all the overflow scrollbars on all ContentPanes, some I do not want turned off (but this is still good to know in the future).
So I just added an inline css to the ContentPane holding my dgrid and works great.
<div data-dojo-id="bottomGridPane" data-dojo-type="dijit/layout/ContentPane" data-dojo-props="splitter:'true', region:'bottom'" style="height: 240px; overflow: hidden;"> <div id="divGridActivities"></div> </div>
Thanks so much for your help, much appreciated.
Robert,
I'm out of idea with my problem. I had grid nicely displayed with outside contentpane not set to "overflow: hidden" originally. My grid needs the scrollbars to get to all the data:
Then after I set outside contentpane's innerHTML to the layer name, scrollbar for the contentpane shows up. The grid is pushed down a little bit too:
If I set contentpane in HTML file style="overflow:hidden"(setting overflow="hidden" has not effect). That's what I got this:
I can't not to scroll to all the data now. I also tried to add another contentpane above the grid to display layername etc, but the grid won't displayed as nice as the orignal way.
Thanks ahead!
Sandy
Sandy,
You should start a new thread with your specifics and the code you are using.
Robert,
I thought my question was related to the original question and that's why I posted here.
After many tries, I accidently found the tricky way to make it look the way I want:
In HTML file, I added a space character to reserve a #text node in the outside contentpane:
<div id="tableDiv" data-dojo-type="dijit/layout/ContentPane" region="bottom" splitter="true" style="overflow: hide"> </div>
Then I programmably change the #text node value to layer name. Then it as the way I want.
I didn't know this is the best answer so I didn't post it.
Thanks