Learn how to a build a cloud-first strategyRegister Now


DataPager - hide previous button (image type) when needed

Posted on 2009-02-13
Medium Priority
Last Modified: 2012-05-06
I am using a data pager with next previous pager fields (as images).  When the previous button is not a valid option, I would like it to be more visibly apparent.  For example, swapping out the image for a "grayed out" version, or simply just hiding the previous button.  How can I accomplish this?
<asp:DataPager ID="pgProducts" runat="server" PagedControlID="lvProducts" PageSize="3">
                            <asp:NextPreviousPagerField ButtonType="Image"  
                                PreviousPageImageUrl="/images/back.gif" />

Open in new window

Question by:centdevs
LVL 11

Accepted Solution

jmwheeler earned 2000 total points
ID: 23633514
There is a property on the NextPreviousPagerField called RenderDisabledButtonsAsLabels, you can set that to true.  You could then use CSS to modify the label as necessary.

Author Comment

ID: 23633538
Wonderful that worked, thank you!!

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Loops Section Overview
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Suggested Courses
Course of the Month21 days, 1 hour left to enroll

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question