asp,net gridview help

Soldato
Joined
1 Feb 2006
Posts
8,188
hey guys,

completely new to asp.net but doing some work here involving gridview for populating tables. I have set up paging and i am trying to work out how to get my next and previous buttons to maintain the same position.. i.e. i always want the next button on the left and previous on the right but when i come to the last page the previous button bounces over the left.. is there any way to keep the button positions constant?

the only code i can find that seems linked to paging is:

Code:
<PagerStyle CssClass="pagingtext" HorizontalAlign="Left" />
<PagerSettings NextPageText="Next" PreviousPageText="Previous" FirstPageText="First" LastPageText="Last" Position="Bottom" />

Any ideas?
 
i dont think off the top of my head there is any way to do this other then create a custom footer.

it is to me a bit strange to reverse the buttons but i guess you have a reason for it.

for me the previous button should be on the left always.
 
sorry i described this wrong in the first place but anyways the problem is solved... the existing css files i was working with had some conflicting entries and it was messing up my formatting! Thanks anyways!
 
just adding on from my previous gridview question... is it possible to have two objectdatasource objects to be linked with one gridivew? What I am trying to do is have a button to toggle between two queries, the results of which will display in the gridview. The queries will have completely different parameters too so I'm getting quite lost here! Anyone any good with this stuff?
 
just rebind the datagrid with the alternative datasource

or have 2 gridviews and hide / show the relevant one depending on the button.
 
Back
Top Bottom