ADF Pagination - Customize number of visible rows

Hi,
Jdev - 11.1.1.5.0
I want to provide a drop down option to select 'the number of visible rows'. Based on the option, it should display table content accordingly with the specified number of rows.
Ex: I've a ViewObj to be displayed as a table.Table contains around 500 rows. I've dropdown with 50,75,100 values. If I select 50 from the drop down, the total rows will be devided by 50. It means, 10 pages 1,2,3,4,5,6,7,8,9,10 with links pointing to the corresponding 50 rows.
I should be able to see first 50 rows by default. If I click on link 2, it should display rows from 51 to 100 etc. If I click on link 3, it should disply rows from 101 to 150 etc.
Please suggest, if you have any suggestion or pointer on this use case.
Thanks in advance,
Samba

hI,
Thanks for your information.
Able to achieve pagination. But before implementing this process, I am filtering the table content to be display using View Criteria.
After following ADF Traditional pagination, unable to apply validations to filter the content. (http://codeplay.net/2011/04/21/simple-adf-traditional-pagination-2-with-business-component/)
As I've transient attributed, if checkboxStatus = "Y" then only i am displaying those rows. Can you suggest any clue to provide validation on the data before displaying the content with pagination.
-Samba.

Similar Messages

  • Scrolling table. Getting Number of Visible rows from User Settings.

    Hello everyone,
    I hope you can show me the way to the light! here is my problem:
    I have to control the scroll of a table, for allow to the user to see always one blank row for entry proposes.
    For that I know that I can ge the number of visible rows and the first visible row through the methods:
    cl_wd_table->get_visible_row_count( ).
    cl_wd_table->get_first_visible_row( ).
    The problem is that the user can modify the number of visible rows through the user settings in the table ( right button on the table "User Settings->more..." ) and it doesn't modify the value returned by the method cl_wd_table->get_visible_row_count( ).
    How could I get the visible rows set up by the user in his user settings for control the scroll dynamically?
    Many thanks in advice.
    G.

    Hi G,
    The changes what user will be making will be classified as personalization.
    I was looking into the ways of finding the user specific personalization in the code and then callin the mthod set_first_visible_row.
    There are few classes related to personalization like CL_WDR_PERSONALIZATION_SERVICE and CL_WDR_PERS_MANAGER.
    I tried calling method get_pers_data of class CL_WDR_PERSONALIZATION_SERVICE. But for me it was not returning any data.
    You can also look into these classes and try to fetch user specific personalized data with methods available.
    Another way which I thought is to create a component  configuration and make the number of rows as Final so that end user is not able to personalize this ( I know u won't agree on this  ).
    @ Thomas: Any specific inputs from your side on this problem.
    Regards
    Manas Dua

  • JTextArea - number of visible rows

    Hi,
    I have a JTextArea wihch has a dynamically width and height. that is depending on the size of the window (JFrame).
    I am setting the size of JTextArea with pixels via "setBounds", so I do NOT use the constructor JTextArea(width, height)
    1) How do I get the number of visible rows?
    Let say JTextAreas has 20 visible rows. The textfile has 60 lines.
    Say, I scrolled to the middle, so 20 rows before, and 20 rows after are not visible.
    2) How do I get the value 21. (I don't mean the cursor position. At this scrolled-scene, rows between 21 and 40 are displayed.)
    thanks
    Aykut
    Background:
    I am trying to read the content of a very big textfile 100MB to 10GB in JTextArea.
    Via "File" it is not possible to do this. Via "RandomAccessFile" it is (I think) possible.
    So I will try only to read the content of the textfile which fits to the current visible part of the JextArea.

    solution for question 2 is: in 2 steps:
    step 1
    // JSCROLL Listener
        class MyAdjustmentListener implements AdjustmentListener {
            // This method is called whenever the value of a scrollbar is changed,
            // either by the user or programmatically.
            public void adjustmentValueChanged(AdjustmentEvent evt) {
                Adjustable source = evt.getAdjustable();
                // getValueIsAdjusting() returns true if the user is currently
                // dragging the scrollbar's knob and has not picked a final value
                if (evt.getValueIsAdjusting()) {
                    // The user is dragging the knob
                    return;
                // Determine which scrollbar fired the event
                int orient = source.getOrientation();
                if (orient == Adjustable.HORIZONTAL) {
                    // Event from horizontal scrollbar
                } else {
                    // Event from vertical scrollbar
                // Determine the type of event
                int type = evt.getAdjustmentType();
                switch (type) {
                  case AdjustmentEvent.UNIT_INCREMENT:
                      // Scrollbar was increased by one unit
                      break;
                  case AdjustmentEvent.UNIT_DECREMENT:
                      // Scrollbar was decreased by one unit
                      break;
                  case AdjustmentEvent.BLOCK_INCREMENT:
                      // Scrollbar was increased by one block
                      break;
                  case AdjustmentEvent.BLOCK_DECREMENT:
                      // Scrollbar was decreased by one block
                      break;
                  case AdjustmentEvent.TRACK:
                      // The knob on the scrollbar was dragged
                      break;
                // Get current value
                int value = evt.getValue();  // how many pixels from the row 0 to the top of the visible JTextArea, if you scroll just once, than it is the same as fontHeight
                System.out.println("value = "+value);
                System.out.println("fontHeight = "+fontHeight);
                current_scroll_position = value / fontHeight;
                System.out.println("current_scroll_position = "+current_scroll_position);
    step 2
    AdjustmentListener listener = new MyAdjustmentListener();
    text_pane.getHorizontalScrollBar().addAdjustmentListener(listener);
    text_pane.getVerticalScrollBar().addAdjustmentListener(listener);

  • Number of visible rows

    hi,
    I want to display all the records of the table without restriction. Normally If I have 1000 records then the number of visible rows will be equal to the length of the table and we get scroll option to see the other records. If I want to make the number of visible rows equal to number of records is it possible?
    thanks,

    Hi,
    Assign the count of records to the 'No of rows' property of the table.
    Regards
    Basheer

  • How to group by a number of visible rows in drill down report

    hi,
    i have a drill down report with no detail row. 
    I need to control the number of rows shown on the page based on a variable that a user supplies, however it  needs to be only visible rows.
    if I add an outmost group based on an expression like this one:
    =Ceiling(RowNumber(
    "table1")/Parameters!recordsPerPage.Value)
     it will count all rows - visible or not.
    any help would be appreciated.
    thanks
    Inna

    Hi Inna,
    Based on my research, a drilldown report is a layout design that at first hides complexity and enables the user to toggle conditionally hidden report items to control how much detail data they want to see. Drilldown reports are used to change the report
    layout interactively. So it wouldn’t affect the rows displayed in the outmost group. Though some rows are hidden when the report is initially run, it will still count them. This is by design.
    Furthermore, if I understand correctly, you also expect the outmost group is a dynamic group depends on the drilldown action, right? As per my understanding, this function still cannot be achieved at this moment.
    Thanks for your understanding.
    Regards,
    Katherine Xiong
    If you have any feedback on our support, please click
    here.
    Katherine Xiong
    TechNet Community Support

  • Number Of Visible Rows in a ScrollPane

    Hi All,
    I'm a little embarassed about needing help with something like this but I've tried several approaches and I'm just not getting it!
    I have a JTextArea inside a JScrollPane and basically I want to introduce a little algorithm where I set the min, max and preferred sizes of this combo-widget to control real-estate usage (ie. only take up the minimum number of rows to display the text, but never more than a maximum configured by the user - it's a little different from the default behavior)
    I would need a way of querying the JScrollPane to find out how many visible rows he's actually displaying at a moment in time.
    My most promising (but flawed) attempt so far has been to set a listener on a viewport change event, and then to get the viewport extent height and compare it to the JTextArea's string height (which I was hoping coresponded to the height for one line of text).
    double viewPortHeight = vp.getExtentSize().getHeight();
    // get the height of one line of text to determine the
    // number of rows being used
    double textHeight = textArea1.getBounds().getHeight();
    ...but of course they're tracking one another. How do I get the height of a single line???

    Hi Dubwai,
    I'm not sure I understand what you are trying to
    achieve. Could you explain more about why you have > to constantly resize?Basically, the JTextArea/JScrollPane combo will be used in a table renderer for a few very important string columns in a table. There is no upper limit on the amount of text which can be entered in the column and the information in those columns is important enough that the customer has specified that they would like the entire thing to be visible as often as possible. They are defining a maximum number of rows (5-6) for one entry beyond which I will be able to put a scrollbar up. The width of the column for these fields will be fixed (at about 40 chars).
    Additionally, real-estate in the table is at a bit of a premium I also don't want to waste any space in it by showing 2 rows for an entry where 1 row would suffice.
    In a nutshell, I need a text area that is aware of how much space it requires and which will always try to minimize the number of rows it takes up. I thought that by determining how many rows were necessary for displaying a given bit of text, that I could force the JScrollPane size accordingly.
    I'll spend some time looking at setRows(), but from looking at the API I got the impression that that only ultimately affected the preferred size. I was really hoping for a bit more control - for these specs, the minimum, maximum and preferred size will all be the same.

  • Number of Visible rows on the "Leave History" Table

    Dear SDN,
    please, how can I set the height of the "Leave History" table on the PZ54 ESS transaction ?
    The user is requesting more visible rows, but the table only displays 2 rows, and I can't find on the SDN how I can set this table property.
    --> This transaction can be accessed through the Portal, under ESS -> Leave -> Leave Application / Leave History, which is an ITS for the PZ54 transaction.
    Thanks in advance,
    Fabio

    This issue was fixed on post ITS iView height is compressed at first run

  • Number of visible text fields

    Hi all,
    Trying to upload document numbers from Excel into SAP via transaction F-03 using SAP GUI Scripting.
    My approach is to enter values one by one and press Enter when the last visible text field is reached. Then enter another batch of values, press Enter and so on..
    The problem is that I do not know how to get that event when the last visible field is reached.
    I know the solution but for tables when you can count a number of visible rows (.visibleRowCount).
    Thanks in advance.

    Hi Dmitry,
    in this case, I would proceed as follows:
    1. before the position command the system error handling switch off with
    on error resume next
    2. behind the position command the test of error number with
    if err.number < 0 or err.number > 0
    For example:
    on error resume next
    err.clear
    'position command from existing script
    if err.number > 0 or err.number < 0  then
    'processing . . .
    end if
    on error goto 0
    Declaration on the solution: In a non-relevant line will it not work. This one can evaluate it.
    Regards,
    ScriptMan
    Edited by: ScriptMan on Apr 19, 2010 7:36 PM

  • Visible Row Count

    I wish to have paged results(something like 10-20 rows out of
    a few hundreds) in a data grid. When resizing the screen, the
    datagrid changes size, and thus the number of row displayed
    changes. I did not find the property or function which allows me to
    bind unto in order to get the number of visible rows.
    DataGrid.rowCount is 0 unless set, and it is not bindable. Any idea
    how I can find that information?

    Hi,
    1) The rowCount is the right property. It is zero until the
    app is finished laying out and sizing all components.
    2) rowCount IS bindable; it just does not dispatch an update
    event, so if for instance a Label's text property is bound to
    DataGrid.rowCount, it will always read zero.
    So what you really need to do is get the rowCount AFTER the
    application's creationComplete event, and whenever the DataGrid
    changes its size.
    The following code uses the app's creationComplete event to
    get the initial rowCount property and display it in a Label. I also
    add an event handler for the DataGrid's render event, which is
    fired whenever the DataGrid has to re-draw itself.
    There may be an easier way to do it. Maybe someone else has a
    more elegant solution. Hope this helps.

  • TableView -- get the row number of the top most current visible row

    Is there any way to get the row number of the top most visible row, and or bottom most visible row in TableView?

    If you already know the document's name, the sheet's name and the table's name, the easy way is :
    --Here you may replace the three values by the current ones
    set dName to 1
    set sName to 1
    set tName to 1
    tell application "Numbers" to tell document dName to tell sheet sName to tell table tName
    tell first cell of the selection range to set {rowNum1, columnNum1} to {address of its row, address of its column}
    tell last cell of the selection range to set {rowNum2, columnNum2} to {address of its row, address of its column}
    end tell
    Yvan KOENIG (VALLAURIS, France) mercredi 9 février 2011 17:22:21

  • How to Customize the Message "No Row Returned" from a Report

    Hi,
    I've been trying to customize the Message "No Row Returned" from a Report.
    First i followed the instructions in Note:183131.1 -
    How to Customize the Message "No Row Returned" from a Report
    But of course the OWA_UTIL.REDIRECT_URL in this solution did not work (in a portlet) and i found the metalink document 228620.1 which described how to fix it.
    So i followed the "fix" in the document above and now my output is,..
    "Portlet 38,70711 responded with content-type text/plain when the client was requesting content-type text/html"
    So i search in Metalink for the above and come up with,...
    Bug 3548276 PORTLET X,Y RESPONDED WITH CONTENT-TYPE TEXT/PLAIN INSTEAD OF TEXT/HTML
    And i've read it and read it and read it and read it and can't make heads or tails of what it's saying.
    Every "solution" seems to cause another problem that i have to fix. And all i want to do is customize the Message "No Row Returned" from a Report. Please,...does anyone know how to do this?

    My guess is that it only shows the number of rows it has retrieved. I believe the defailt is for it to only retrieve 50 rows and as you page through your report it retrieves more. So this would just tell you how many rows was retireved, but probably not how many rows the report would contain if you pages to the end. Oracle doesn't really have a notion of total number of rows until the whole result set has been materialized.

  • How to increase the ALV visible row count

    Hi Experts,
    My standard ALV display is displaying only 10 rows.
    My requirements is to display 20 rows.
    Please advise.
    Regards,
    Chitrasen

    hi ,
    u can set the row count to any number , here I am setting it to 5 using the method set_visible_row_count
    1 Change the visible row count to u20185u2019
      DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.
      lo_cmp_usage =   wd_this->wd_cpuse_alv( ).
      IF lo_cmp_usage->has_active_component( ) IS INITIAL.
        lo_cmp_usage->create_component( ).
      ENDIF.
      DATA lo_interfacecontroller TYPE REF TO iwci_salv_wd_table .
      lo_interfacecontroller =   wd_this->wd_cpifc_alv( ).
        DATA lo_value TYPE REF TO cl_salv_wd_config_table.
        lo_value = lo_interfacecontroller->get_model(
        lo_value->if_salv_wd_table_settings~set_visible_row_count( '5' ).
    u can also go thru this useful links for CONFIGUIRING ALV :
    http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/40794172-b95a-2910-fb98-b86d8a0918b4;jsessionid=(J2EE3417400)ID0488867050DB10849380333905377829End
    SAP List Viewer (ALV) [original link is broken]
    Configuring ALV
    http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/1190424a-0801-0010-84b5-ef03fd2d33d9?overridelayout=true
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/db22242d-0701-0010-28a2-aeaa1fefd706;jsessionid=(J2EE3414800)ID0133346050DB00727847586176044227End?overridelayout=true&bcsi_scan_06B6B0A4B65849C2=0
    I hope it shud solve ur query.
    regards,
    amit

  • How to get  visible row  count  in JTable ?

    I have one table which is added to one scroll pane. For example my table have total 1000 rows, but at a time only 20 rows should be visible to the scroll pane. And I want to scroll the rows and show only 20 at a time.When user scrolls JTable then next time he can view only 1 to 21, then 2 to 22, and so on. I want to know how to get that number which represents the visible row( in this case it is 20).So kindly help me how to get visible row count. Any help regarding this will be appriciated.
    Thanks and Regards,
    Sheetal

    how to get visible row count.First you need to get the viewport used by the scrollpane. Then you can use methods like getViewPosition() and getViewSize() to get information about the current postition of and size of the viewport.
    Then you can use the table method getRowAtPoint(). to determine the first and last visible row which can then be used to calculate the visible row count.
    When user scrolls JTable then next time he can view only 1 to 21, then 2 to 22, and so onThis is the default behaviour when a "block" scroll is done.
    However when you click on the arrow button on the scrollbar it will only scroll a single row. You could override the getScrollableUnitIncrement() method to return the value from the getScrollableBlockIncrement() method.
    However the user can still drag the scrollbar manually which would cause a problem. So you would also need to remove the MouseMotionListeners from the scrollbar to prevent this.

  • Visible Rows - Web Enterprise Designer

    hi all,
    i'd like to know if there is someway how to put from Page Wizard - Page
    Options the attribute Visible Rows = Total Rows (of the table already
    implicated). I have a HTML Page wich is a "List". i do not want to put a
    limit, i just want the limit be the same as the number of rows in the table.
    the "visible rows" attribute allows to put a number only, but not a
    function.
    thanks in advance.
    ==
    Carlos Fern&aacute;ndez
    Forte Software Engeneer
    IBC USA
    Carlosibcweb.com
    There is not teacher
    who can teach anything new
    He can just help us to remember
    the things we always knew.

    Hi HG,
    Please restart your BI server it happens normally that evern after we activate the template from BI content and maintain the template in SPRO and it still dont reflect any changes.
    Once u wil restart your BI server u will be able to get it into WAD.
    Thanks
    Dipika

  • How to retrieve the number of "free" rows in a table?

    Hi,
    if in a client only environment (no sync to mobile server) rows are inserted and deleted into a table,
    is there a way to retrieve the number of "free" rows in a table? Number of "Free" rows stands for
    number of rows that can be inserted again, before the table extents in size.
    Is there a way in OLite 10.3.0.2.0 to retrieve the size of tables and indexes? ALL_TABLES is not
    a place that really works.
    Best regards and many thanks,
    Gerd

    Hi Gary,
    many thanks, the partner uses a Lite client db without sync. The db runs inside an laboratory device and collects measures. There must be a way to estimate the the number of "measures" rows, that stil can be stored in the db.
    Than we need to make the deleted space available for new rows. The partner tested defrag.exe and found that it
    needs very long time to run, especially if the db is bigger than 2GB. ... and that this run sometimes fails.
    Is there any recommendation the partner can follow on?
    Thanks,
    Gerd

Maybe you are looking for

  • Ipod nano issues / someone please help

    i cant get the ipod to change to english right now it is in japenese or something please help me .

  • Why cant i open my itunes

    my itunes wont open what can i do

  • DateFormat.parse

    Hi all, I am trying to parse some Strings into date objects, but i'm getting some strange output. The dates (Strings) that go into my program are: 2005/3/08 09:12:38 2005/3/10 17:29:57 2005/3/11 15:39:59 2005/3/23 13:30:03 2005/3/23 13:32:49 my code

  • How to publish Report Viewer reports as Web Services

    I have some reports templates (.rdlc) having only business objects as data sources (no direct SQL connection). They are working well with Windows Report Viewer. Now I am think to make the reports available via web services to multiple apps. Is there

  • Iweb photo page and pay pal buttons

    could someone tell me how to alter or change java so pay pal buttons go away when someone clicks on picture to enlarge or goes to slide show? cyclosaurus gave to example web pages that it can be done, but no explanation on how to do it. Thanks , wish