954,574 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Hide the page index from pager row

hai
I have a grid that include paging and i created pagesize drop down for page sizing.
I use PreRender event for displaying this pagerrow even if the row count not exeeds the pagesize.
My problem is, in pager row the page index also dispalyed with page size dropdown as '1'.
Can i hide it or any other solution for this problem.

Thanks in Advance,
Sreevidya

ssreevidya.m
Junior Poster in Training
51 posts since Jan 2009
Reputation Points: 10
Solved Threads: 0
 

Use an if statement to check if that is the only value, if so set visible to false for the control you'd like to hide.

Something similar to this will work:

//this is using an inline if statement
control.Visible = control.length > 1 ? true : false
stbuchok
Master Poster
730 posts since May 2011
Reputation Points: 120
Solved Threads: 93
 

hai ,
I want to display only the pagesize-dropdown in the pager row without page index.
For that can I set the FirstPageText as empty. I tried like following, but it didnt work.

Gridview1.PagerSettings.FirstPageText = "";

Thanks in advance,

Sreevidya.

ssreevidya.m
Junior Poster in Training
51 posts since Jan 2009
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: