Paging a Table

Could someone help me with the code to maintain the data when paging the table. I populated the table based on the role that the user selected in a drop down. Here is my existing code.
Protected Sub ddkRolesList_Select(ByVal sender As System.Object, ByVal e As SAP.Web.UI.Controls.AbstractDropDownByKey.SelectEventArgs) Handles ddkRolesList.Select
Dim um As New UserManagement
Dim role As String = ddkRolesList.SelectedKey.ToString()
Dim users As Array = um.GetUsersOfRole(role, True)
Dim user As String
For Each user In users
Dim tRow As New TableRow()
Dim tCell As New TableBodyCell()
Dim tCell2 As New TableBodyCell()
Dim tCell3 As New TableBodyCell()
tCell.TableCellContent = New TextView(GetName(user))
tRow.Cells.Add(tCell)
tCell2.TableCellContent = New TextView(GetEmail(user))
tRow.Cells.Add(tCell2)
tCell3.TableCellContent = New CheckBox()
tRow.Cells.Add(tCell3)
Table1.Items.Add(tRow)
Next
End Sub
Thanks,
Gabe Petro

Hi Gabe,
how are you doing ?
have you informed yourself of the links presented by Ofer in the following thread : Portal User Management via .Net   ?
that is the methodology to be able to access the UM from within NPDK
comming to the code :
the logical steps in your case
1> read portal object
2> create local copy of data object
3> create local data table
4> create default view and bind grid
they are over engineered, but none the less should yeild the result you require
what result do you get with the code ?
um.GetUsersOfRole(role, True)
please check the methods
1> GetUserName
2> GetUserEmail
as they are outside the scope of the current function
with respect,
amit
Private Sub BuildTable(ByVal roleID As String)
Dim um As New UserManagement()
Dim role As String = roleID
Dim users As Array = um.GetUsersOfRole(role, True)
Dim user As String
tblRoleA.Header.Text = "Users of " & ddkRoleA.SelectedItem.Text
Dim usersTable As New DataTable
Dim myDataRow As DataRow
Dim myDataView As DataView
usersTable.Columns.Add("Name", Type.GetType("System.String"))
usersTable.Columns.Add("Email", Type.GetType("System.String"))
' Iterate FileInfo objects to populate the DataTable.
For Each user In users
myDataRow = usersTable.NewRow()
myDataRow("Name") = GetUserName(user)
myDataRow("Email") = GetUserEmail(user)
usersTable.Rows.Add(myDataRow)
Next user
' Create a new DataView and sort it based on the sort field.
myDataView = usersTable.DefaultView
'myDataView.Sort = strSortField
tblRoleA.DataSource = myDataView
tblRoleA.DataBind()
End Sub

Similar Messages

  • ADF 11.1.1.2.0 paging in table. How to do this?

    Hi,
    I am using ADF 11.1.1.2.0 with ADF 11g.
    I am looking to do paging in various tables that I have created frm the VOs. I do see that older ver. of ADF had a direct and a declarative approach to do paging but in ADF 11.1.1.2.0 does not seem to have that support.
    What is the simplest way to achieve this. Basically user should see a next and previous button/link and it will fetch the next/previous set of records, without creating too many objects.
    Pls guide.

    There is no direct solution in adf rich faces for page navigation like if was present in 10g. You can do this if you use trinidad tables.
    Paging is done implicit when you scroll down/up the adf table. If you don't like it you can try to implement it yourself.
    Timo

  • Need help with paging in table layout

    Hi
    I am creating a basic table-form page with around 5000 rows in database table that needs to be displayed.
    However what i see after creating the table form page and adding detail groups i loose paging in the table layout.
    This is however undesirable.I cannot think of what is exactly making this happen there are no significant changes that i have made to the application.
    If I could know what possibly is causing the change, help would be appreciated.
    I can discuss this in detail.

    Which version of JHeadstart are you using?
    What do you mean with "i loose paging in the table layout"? Are the previous/next set and drop down list to select a range no longer displayed?
    Can you reproduce this in the HR demo applcation?
    If you remove the detail groups again, is pagination then working again.
    Steven Davelaar,
    JHeadstart team.

  • Server side paging hughe tables.

    Hi,
    If I want to do a findAll () on a serious big table (million records), I need a paging mechanism, to avoid an out of memory exception.
    This table has a primary key consisting of one (String) field, so no complex stuff there. Is there any easy way to do this with ejbql? I'm using weblogic 6 as the application server.
    Cheers.

    forget about ejbql...
    ejbql is not good solution for big table
    use fast lane pattern, and directly access database.
    This is oracle example.
    oracle hint and inline view and good index is key point.
           String query= "select "+REQUEST_LIST_SELECT+" from "+TABLE_SERVICE_REQUEST +","+
                    " (select /*+ INDEX_DESC("+TABLE_SERVICE_REQUEST+" "+INDEX_SERVICE_REQUEST+")*/ "+
                    "  ROWNUM NUM,SERVICE_CODE from "+TABLE_SERVICE_REQUEST+
                    " where ROWNUM<="+(offset+numberPerPage)+
                        getServiceRequestWhere(searchStart,searchEnd,keyward)+
                    " ) indexer "+
                    " where NUM>"+offset+" and indexer.SERVICE_CODE="+TABLE_SERVICE_REQUEST+".SERVICE_CODE "+
                    " order by SERVICE_CODE desc";

  • Sorting issue in Pojo Datacontrol Filter-Paging ADF Table

    hi,
    Created and af:table using sample given at ADF Code Corner 037. How-to build pagination into ADF POJO Data Control(http://www.oracle.com/technetwork/developer-tools/adf/learnmore/37-adf-pojo-pagination-169179.pdf).
    with this sample, able to get pagination and implemented filtering by overriding queryListener.
    but there is an issue with sorting, even though sortListener() is implemented, when a column is sorted from UI ..
    First ADF inbuilt sort is getting called, getAllDepartments(int index, int range) is invoked TotalRecords/Range times.
    Second sortListener() method is getting invoked.
    is there any way to skip the first step? so that i can write my own Sort logic in SortListener() and trigger the Iterator progrmatically?
    -thanks

    Hi Arunkumar,
    Thanks for your reply. But for custom table, how to create that filter model ?
    When i create the table by dragging it from view, filter model is assigned by default to query descriptor.
    But for this case, how to set the filterModel attribute ? Do i need to create any custom filter model class here ?
    If yes, how to write that. let me know any pointers.
    Please let me know in this regard.
    Thanks,
    Mahipal

  • Jsp table data.

    I have a jsp page, where it retrieves some data from database and displays the resulting records in html table.
    problem is that when the table grows, it is hard to keep track of the header labels for the data when we scroll down the data...
    so I was wondering if we can freeze the table header while allowing to scroll through the data...
    I know that we can do this using frame..but I ain't like frames..and I got to know that for IE we have solution..using
    'overflow' attribute of div element...but it ain't work for NN4.7....
    Any ideas or workarounds for this.........

    I agree with jussist. Just create the headers again every 10-20 rows or so.
    However, I don't agree that using paging on tables is that big a deal. I think it all depends on where the data is, of course. But lets say you have one global table for everyone, then all users can read this same table. Then paging is trivial because you can take a subset for each page per user.
    For larger data sets this is going to be faster then sending all data, and it will definitely be perceived faster by users because the browser has to render less. The problem with tables in most browsers is until the </table> tag shows up, they don't usually show anything for the table.
    The Section 508 requirements don't require supporting specific browsers, that I'm aware of. They only require certain elements must be present in pages (alt tags, etc). Of course it doesn't help when trying to design dynamic pages, which I do a lot of, which sucks, but I guess is good for NN4.7. But, IMHO, NN4.7 is so much crap, at least compared to NN7 and IE6 and the standards.

  • OBIEE 11g: Freeze Column Headers?

    Hello experts,
      I am still new to 11.1.17 and my boss wants me to have the report’s panes frozen, just like in excel.  Does anyone if there is an easy way to do this besides going through the instanceconfig.xml? Just through analysis
    I was thinking from 11.1.1.6 may be things have improved.  Anyone with a full step by step instructions?
    Will surely appreciate the help  

    If that is the case you can follow 10g style of paging in table view to achieve both
    http://bischool.wordpress.com/2009/08/24/pagination-or-page-contol-in-obiee-pivot-view/
    Thanks,
    Saichand

  • Skin resource bundle

    Hi,
    I'm using a paged af:table and getting in the logs "<RenderingContext> <getTranslatedString> Could not fetch resource key Page from the skin myskin.desktop" (roughly translated).
    Solution in non-portal application is to specify resource bundle with specified key in trinidad-skins.xml/skins/skin/bundle-name but what is the proper solution in a portal application if I still want to allow for runtime selection of skin?
    The "update portal resource" dialog does not provide input of resource bundle name.
    The generated generic-site-resources.xml contains a reference resourceBundle="oracle.webcenter.framework.translations.TranslationsMDSResourceBundle" that indicates there might be some proper place to put skin bundle resources. (I tried editing the xml manually testing changing resourceBundle="MyBundle" and also adding <customAttribute name="skinBundleName" seeded="false" value="MyBundle" visible="ALWAYS"/> but to no avail).
    Best bet, if it is indeed possible to translate the "???Page???" in an af:table in a portal application, would be to add something to ResourceLibraryBundle but I don't know what trans-unit id.
    There's a handful of this exact question (e.g. https://forums.oracle.com/message/10620083) but no answers, either the solution is very obvious or there is no solution other than hard-coding the skin (which would not be that much of a problem).
    Any ideas?

    Thank you again!
    I'm using JDeveloper 10g.
    First, I've created a custom resource bundle (com.ieci.mugeju.view.resource.MugejuResourceBundle) and overrided the default resource string values.
    Second, I've created the file adf-faces-skins.xml like this:
    <?xml version="1.0" encoding="windows-1252" ?>
    <skins xmlns="http://xmlns.oracle.com/adf/view/faces/skin">
    <skin>
    <id>MugejuSkin</id>
    <family>MugejuSkin</family>
    <render-kit-id>oracle.adf.desktop</render-kit-id>
    <bundle-name>
    com.ieci.mugeju.view.resource.MugejuResourceBundle
    </bundle-name>
    </skin>
    </skins>
    Third, I set the skin-family property of the file adf-faces-config.xml to 'MugejuSkin'.
    If I follow all these steps, I achieve to change the text in ADF Faces components, as I wanted, but I lost the oracle styles (skin-family = oracle) that I had before following these steps.
    I must be doing someting wrong. I would like both, to mantain the oracle styles and to change the text in ADF Faces components.
    Thank you very much.

  • Problems with Adobe Interactive Forms

    Hi,
    I'm working on a report that have a header with two dynamic tables (with fixed rows count) and the body have other two dynamic tables with a large amount of data.
    The first doubt is:
    I put my header on the Master Page, and in the first page of report, the header data appears ok, but when the second page comes, just the data contained in the root node appears in the header. Neither the data contained in a node 1..1 appeared.
    The second doubt is:
    In the report body, I've two dynamic tables with a large amount of data, so, when my table reach the end of the page, I need to add a page break and continue in the next page, adding the column header again. I'm trying to set the "Allow Page Breaks within Content" and "Overflow Leader", but I can't set these properties in a subform of type "Flow Content", flow direction "Table". So, how can i add Page Breaks ?
    Thanks in advance
    []'s

    Perhaps your interpretation of the Master Page is different than mine.  I never put anything but static content in my Master Page.  For instance for the form in my weblog my Master page has a head with a logo and Footer with a page number and some static text. 
    In my Master Page I have single Page that I called MainPage. I then create a Content Area within this MainPage. 
    All of my variable elements go into a separate Page.  I set that entire page object as Flow Content (flow direction Top to Bottom) with Allow Page Breaks within Content marked.  I set the Place to (in Content Area "Name" where Name is the name of the Content Area in the Master Page).  The After is set to Go To Page MainPage(Back to the Master Page Object). 
    With this my paging with tables and Master Page content all work correctly.  I can do page breaks and repeat my table headers, but continue the content normally.  Hopefully this helps.

  • Problems with Adobe Forms

    Hi!
    I'm having a problem, when I insert a static text on my form and press the activation button it happens 2 things:
    1) the text on the static text erases
    2) the form doesn't activate
    If anyone can help me with any of my doubts, I'd be very pleased.
    Thanks!

    Perhaps your interpretation of the Master Page is different than mine.  I never put anything but static content in my Master Page.  For instance for the form in my weblog my Master page has a head with a logo and Footer with a page number and some static text. 
    In my Master Page I have single Page that I called MainPage. I then create a Content Area within this MainPage. 
    All of my variable elements go into a separate Page.  I set that entire page object as Flow Content (flow direction Top to Bottom) with Allow Page Breaks within Content marked.  I set the Place to (in Content Area "Name" where Name is the name of the Content Area in the Master Page).  The After is set to Go To Page MainPage(Back to the Master Page Object). 
    With this my paging with tables and Master Page content all work correctly.  I can do page breaks and repeat my table headers, but continue the content normally.  Hopefully this helps.

  • Still getting Javascript error with new version of UIX

    I'm facing some problem after changing my UIX framework version (2.2.3030829.1626).
    Currently I'm using UIX version (2.2.3030829.1626) . Paging with table is not working with new frame work .
    It is giving me javacript error "object doesn't support property or method" when clicking 'Next' .
    It's working fine with old version.
    We had used proper cabo directory. These files are in sync with the version of the runtime
    Here is our finding
    I found a error in _updateFormActions() function from MarlinCoreb2.js file.
    In this function it is giving error at
    if(a8!=a6)
    a7.action=a6 line (line # 1841,1842). If I comment out this two lines page is
    working properly without any javascript error.
    This problem is a bit tricky....
    Because it seems to be a problem with the UIX framework that only occurs on some versions of the Internet Explorer. On some version (IE 6.0.2600.0000) it works fine
    and it also works on the Mozilla Firefox browser.
    Can any one advice on the same?
    Thanks in advance
    Anindya

    I answered this question on a different thread.
    Do NOT post the same question multiple times. If you require more complete or prompt assistance than you receive on these forums, contact Oracle Support.
    -brian

  • Javascript error with new UIX framework

    Hi,
    I'm facing some problem after changing my UIX framework version (2.2.3030829.1626).
    Currently I'm using UIX version (2.2.3030829.1626) . Paging with table is not working with new frame work .
    It is giving me javacript error "object doesn't support property or method" when clicking 'Next' .
    It's working fine with old version.
    Any help is much appreciated.
    Thanks and Regards,
    Anindya

    Thanks Brian for your prompt reply
    We had used proper cabo directory. To confirm it we have done it once again.But we're still getting the same error.
    here is our finding
    I found a error in _updateFormActions() function from MarlinCoreb2.js file. 
    In this function it is giving error at
    if(a8!=a6)
    a7.action=a6 line (line # 1841,1842). If I comment out this two lines page is
    working properly without any javascript error.
    This problem is a bit tricky....
    Because it seems to be a problem with the UIX framework that only occurs on some versions of the Internet Explorer. On some version (IE 6.0.2600.0000) it works fine
    and it also works on the Mozilla Firefox browser.
    can you please advice is there any solution
    Thanks in advance
    Anindya

  • Implementing pagination

    Hi,
    Pls suggest for implementing pagination with af:table.
    I referred the link http://wiki.apache.org/myfaces/WorkingWithLargeTables . It looks like too many changes required.
    We have to implement pagination for 5 tables in our app.
    Thanks
    Tilak

    Tilak,
    You don't indicate what you use for your model layer (the link you posted describes how to make a fetch-on-demand model). If you are using ADF Business Components as your model layer, then any of tr:table, af:table (10g - with paging), af:table (11g - with scrolling) will have this fetch-on-demand automatically.
    If you are building your own data model layer from scratch, then the link you provided is a great start. Yes, it's a lot of work, which is an excellent reason to consider using a framework, such as ADF, where someone (Oracle) has already done this work for you.
    John

  • Issue with ADF table range paging and sorting

    Hello,
    We have a requirement to support pagination in ADF tables. For this, we have made use of Range paging access mode in the view object level. The paging works perfectly fine with this. But we have another requirement of letting the user do a sort on the table (Yes!! The paginated table). The sort should be applied on all rows in the db and the control should return to the first row.
    Applying sort as it is provided by the fwk, sorts the records in the obtained range only. So we have over ridden the Sort listener in Managed bean for this and are able to acheive the sorting of all rows through a AM method call. We are seeing a problem after this. If the sort action is applied to the key attribute then the previous and next range navigation works fine. If the same action is applied to non-key field, then some times (yea!! This is not consistent) the next set is not fetched.
    Here is the code snippet that is called on Next navigation:
    Map<String,Object> pfScope = AdfFacesContext.getCurrentInstance().getPageFlowScope();
    Object objPageNumber = pfScope.get("pageNumber");
    int pageNumber = 0;
    if(null != objPageNumber)
    pageNumber = new Integer(objPageNumber.toString()).intValue();
    BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();
    JUCtrlRangeBinding view = (JUCtrlRangeBinding)bindings.getControlBinding("GeDmRequestVO");
    int iRange = getTable().getAutoHeightRows();
    int currentPage = view.getIteratorBinding().getNavigatableRowIterator().getRangeStart()/(iRange + 1);
    System.out.println("Before " + view.getIteratorBinding().getNavigatableRowIterator().getRangeStart());
    System.out.println("Current : " + currentPage);
    System.out.println("Page Number : " + pageNumber);
    System.out.println("Range : " + iRange);
    System.out.println("Value : " + iRange*(currentPage + pageNumber));
    view.getIteratorBinding().getNavigatableRowIterator().scrollRange(iRange*pageNumber);
    System.out.println("After " + view.getIteratorBinding().getNavigatableRowIterator().getRangeStart());
    Although, the new values are not refreshed in the table, the SOPs for before and after print the proper range sizes. And as I mentioned above, the above code works perfectly fine if there is no sort applied or when key attribute is sorted.
    Would appreciate your help on this regard with navigation after non-key attribute sort.
    Thanks,
    Chitra.

    Hi Chitra,
    Can you specify some links to implement RangePaging.....We need to implement pagination.If possible can you share the code or specify the steps how you achieved it.
    Thanks

  • WD Table:  Repositioning Paging Buttons in Table Footer

    Is it possible to reposition the paging buttons  to appear in the right hand side of the WD table footer?  Is it possible to reposition the paging to appear in the header of the Web Dynpro Table?

    See
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/1011818d-1abe-2910-5897-f72eb59c951a
    Armin

Maybe you are looking for

  • Firewire 800 issue with mac mini

    I just upgraded from a 3 year old mac mini with a firewire 400 port which I connected to my LaCie external hard drive via a firewire 400 cable. The LaCie has 3 USB ports that I connected my printers and scanner to as the 4 ports on the back of the ma

  • SUBMITTING ALV GRID LIST

    Hi, can we call a standard program using SUBMIT and EXPORTING TO LIST TO MEMORY,  which generates output in <b>ALV GRID</b>. Some body saying it is only possible with ALV LIST display, can anyone clarifies me??? it's a bit urgent... Thanks Praneet

  • Creating new nodes dynamically in message mapping

    Gurus, Source Structure is <Phone></Phone> <Phone></Phone> And I want to create target structure as for this Node1 <Phones> <Phone1>Has value from first Phone Node in source</Phone1> <Phone2>Has value from second Phone Node in source</Phone2> </Phone

  • Jinitiator or Sun java plug-in

    I've been reading a lot of posts lately about jinitiator. From what I've been able to understand, it looks like jinitiator is going away and the sun java plug-in is what we should be using. Is there a definitive statement concerning this issue and is

  • Why is Adobe customer service such freaking garbage....

    All I want to do is cancel my damn account, I have been on hold for 30minutes being transferred by one guy somewhere around10minutes in.  The online chat is a joke, waiting 50+ minutes with no acknowledgement.  For a big company this is horrifying an