473,324 Members | 2,257 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

Scroll bar in Grid View

Hi,
I have placed a grid view inside Atlas panel. On click of a button event,
data is populated in the grid view, I want to add scroll bar instead of
increasing the size of grid view.
I have written the following code.

<div id="Layer1" style="width:350px; height:140px; z-index:1;overflow-y:
scroll">

But the problem was scroll bar will be there if there no data aviabale in
the grid .

Hence I have make a condition (checking the row count in the grid ) and put
the code in side that.

Can any one give a better solution for this
Nov 2 '06 #1
2 3827
Use "overflow-y:auto" or simply "overflow:auto" instead.
"Umeshnath" <Um*******@discussions.microsoft.comwrote in message
news:80**********************************@microsof t.com...
Hi,
I have placed a grid view inside Atlas panel. On click of a button event,
data is populated in the grid view, I want to add scroll bar instead of
increasing the size of grid view.
I have written the following code.

<div id="Layer1" style="width:350px; height:140px; z-index:1;overflow-y:
scroll">

But the problem was scroll bar will be there if there no data aviabale in
the grid .

Hence I have make a condition (checking the row count in the grid ) and
put
the code in side that.

Can any one give a better solution for this


Nov 2 '06 #2
Hi,
Thanks for your help.
But I need to optimize little bit this also.
The below code will work but it will reserve space for the grid view.
I have two data grid, one is completed task and other is for hydrated
..Suppose right now I don’t have single item in the hydrated list and I have
few items in the completed list (assume first one is hydrated grid and second
one is completed). In this case it is reserving space (normal height of grid)
for the first grid even though no data in the grid. It looks odd. If no data
is there in the first grid and second has data, second grid has to come top.
(This will work normal scenario, if we are not using div)

Also let me know any other better code. Rather than using div tag

Can any one help for this?

"Reid" wrote:
Use "overflow-y:auto" or simply "overflow:auto" instead.
"Umeshnath" <Um*******@discussions.microsoft.comwrote in message
news:80**********************************@microsof t.com...
Hi,
I have placed a grid view inside Atlas panel. On click of a button event,
data is populated in the grid view, I want to add scroll bar instead of
increasing the size of grid view.
I have written the following code.

<div id="Layer1" style="width:350px; height:140px; z-index:1;overflow-y:
scroll">

But the problem was scroll bar will be there if there no data aviabale in
the grid .

Hence I have make a condition (checking the row count in the grid ) and
put
the code in side that.

Can any one give a better solution for this


Nov 3 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: William Gill | last post by:
I need to display a couple of labels and a checkbox from each entry in my database. Simple enough, but there are several hundred records, and I only want to display 5 or 10 at a time. Can this be...
2
by: Boaz Ben-Porat | last post by:
Hi all Is there a way to simulate a click on a scrollbar (horizontal) of a FataGrid ? I need to programmatically scroll the grid to the right/left upon some condition, when the total width of...
1
by: Jeremy Chapman | last post by:
I've got a grid inside a div so that it's got scroll bars around it. What I want to do is have the header row fixed at the top, so that the vertical scroll bars scroll just the data rows of the...
4
by: sumit | last post by:
Hi, I want to make a datagrid to be scrollable instead of paging in it. So i have put that datagrid html tags inside <div></div> tags and made that div scrollable. Due to this if i scroll down...
3
by: rmunson8 | last post by:
I have added Panel control to a web page which contains a GridView. The Panel's ScrollBars property is set to auto. When I select the Select CommanField button for a row (which obviously causes a...
0
by: memanwar | last post by:
Throughout our system we use the DataGrid. One problem we've noticed is that the arrow buttons don't always work with our grids, clicking on them sometimes won't move the columns at all, or may...
1
by: Robert G | last post by:
I'm using VB .net 2003. I have a grid where everything is working fine except when after the grid is filled with records (by setting the data source to a data view), both the horizontal and...
3
by: EdB | last post by:
How do I capture the position of the vertical scroll bar? I present the grid to a user, they select an item, and I pop up an edit window. When they are done, I need to refresh the grid (editing...
2
by: akm | last post by:
I am facing an issue with the vertical scroll bar. Actually i am using data grid to display the data in my tables, and also i am using the same view form to diplay the data for different tables....
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.