JSTL Change the order in which children tags are processed

Hi there,
Is there any way one can manipulate the order in which tags are executed/processed within for example an iteration tag? I.e. let's say I have the following:
<m:my_iterate_tag data="data">
  <dotag1>XX</dotag1>
  <dotag2>YY</dotag2>
</m:my_iterate_tag/>The user can set as a preference in my application that they want <dotag2> to
be displayed/executed first before <dotag1>, e.g. like in a column in a table. How can I change
the order of these tags when I execute the <m:my_iterate_tag>? Do I do it in
<m:my_iterate_tag> or is there another or better way? Please help.
Thanks,
Marius Botha

Okay, lets start with getting the order in which to display columns... So you say:
get the order of these columns from the db (e.g. client
says 1=title, 2=number, don't display "type" column)Based on the DB, then, create a java.util.List that would have the column names in the order they want... (not real code...)
ArrayList columnOrder = ["title", "number"]
When you get to iter_tag:table.doStartBody, then create a java.util.HashMap (lets say) called tableColumnData.
Then in the iter_tag:column tag, you would the value provided in the tag mapped to the property name as the key in the tableColumnData map:
tableColumnData.put("number", <this iteration's number value>);
tableColumnData.put("title", <the value returned from the g:href tag>);
tableColumnData.put("type", <anything>);
Then, in the iter_tag:table.doEndBody, you do a loop, getting the name of the column to display from the columnOrder list, and using that name to pull the value out of the tableColumnData map:
    for (int i = 0; i < columnOrder.size(); i++) {
        out.println("<td>" + tableColumnData.get(columnOrder.get(i)) + "</td>");
    }You would put the columnOrder in a scope where you won't have to relaod it all the time, like maybe the user's session. You would put the tableColumnDataMap to make sure it is unique to the table... either in the pageContext, or store it in the iter_tag and make a method where the nested tags can retrieve it.

Similar Messages

  • Lion has changed the order in which Finder items are sorted in Icon View; Acc vs. Desc.  How can you change this order?

    The order in which items are sorted has changed in Lion and I can't figure out how, or if, it can be changed.  Previously in Snow Leopard if you sorted by 'Date' in Icon View, your icons would be arranged from oldest to newest.  The same was true for 'Kind' and all the order sort options.  In Kind my *.zip files were positioned last.
    Now in Lion, the order is reversed.  Newest and Zips on top... the accending vs. decnding order has been changed.  How can I change the sort order in Icon View?

    I managed to fix the reverse order issue by deleting the com.apple.finder.plist and com.apple.finder.plist.lockfile in the user library folder. I did have to use terminal to delete the files and then re-launch finder from the force quit window. Here are the step-by-step instructions:
    Hold down the option key while selecting the Go menu. Select Library.
    Navigate to the Preferences.
    Find the com.apple.finder.plist.lockfile and delete it.
    Open Terminal (Application/Utilites)
    In Terminal type in sudo rm (include a space after the rm and do not hit enter)
    Drag com.apple.finder.plist file to the terminal window. It will fill in the path to the file)
    Press return.
    Type in your password and hit return. (The cursor will not move when you type in your password)
    From the Apple menu, select force quit.
    Highlight finder and select re-launch.
    Be careful when using Terminal. There is no undo button and you can accidentally delete important files.
    I hope this helps.
    Henry

  • How can I change the order in which purchased movies are downloaded?

    If for instance, I rent three movies on iTunes Store and decide I want the download of my last pick, to be the first one finished downloading... is there a way to do this?

    Pause the ones that you do not want to be first.

  • How can I change the order in which songs appear in my iTunes Music Library?

    How can I change the order in which songs appear in my iTunes Music Library?

    Kay,
    If you are looking at the entire music library ("Music") you can sort by any of the columns by clicking the column header.  If there is a column you can't see, enable it by going to View > View Options.
    Within a playlist, you can do the same, and in addition you can click above the column of sequence numbers, which will then allow you to drag tracks up or down to get any order you wish.

  • How can I change the order in which photos are presented on an Apple TV?

    I am showing photos on my Apple TV via my Apple MacBook, iTunes and Home Sharing.
    That all works nicely for me, except that I wish to change the order in which a few photos
    are being presented.  How can I change the presentation order on the Apple TV?

    Welcome to the Apple community.
    You'll need to change the order in iPhoto. Open the album you wish to re-order, manually sort them to the order you want, then use the time and date and batch change options as applicable from the photos menu to retag your photos.

  • Change the order in which the processes come up on restart

    Is there a way to change the order in which the processes come up again when restarting the OC4J?

    Hi --
    Do you mean the order of the applications deployed to an OC4J instance, or the processes started by OPMN when OracleAS is started.
    For the former, we put the application entries into a ordered map based on the order they are seen as in the server.xml file. While we don't offer a feature that the applications will definitively be started in that order, we do work our way through the ordered list. So for more parts you'll see the application starting the same order as they are seen in server.xml.
    For the latter, I'm not sure. I also tend to think that its again based on the order within OPMN. What you can try and use is the opmnctl startall sequential=true command, which will sequentially start each process, where it waits for the previous process to start before starting the next one. That will at least show you the order the processes are starting in and help you test the opmn ordering hypothesis.
    cheers
    -steve-

  • Can I change the order in which my different e-mail accounts are displayed in TB?

    I use TB to access e-mails from 5 different accounts. They are displayed in the order in which I added them but I would like to change that order. Is it possible, please?

    Many thanks @Airmail for taking the time to provide the solution.

  • Changing the location to which iphoto & albums are stored/saved

    how do I change the location to which iphoto stores photos and albums including all events rather than my computers hard drive without loosing any information?
    thanks

    Make sure the drive is formatted Mac OS Extended (Journaled)
    1. Quit iPhoto
    2. Copy the iPhoto Library from your Pictures Folder to the External Disk.
    3. Hold down the option (or alt) key while launching iPhoto. From the resulting menu select 'Choose Library' and navigate to the new location. From that point on this will be the default location of your library.
    4. Test the library and when you're sure all is well, trash the one on your internal HD to free up space.
    Regards
    TD

  • ADF: controlling the order in which VO records are inserted

    All,
    in an ADF BC project, we have some complex MD insert pages that add records to master and detail tables at the same time. The application sits on top of CDM RuleFrame, which exposes the datamodel as DB views with instead-of triggers and adds (Designer) a few nifty things like auto-populated PK fields. Sad enough, we can't use these auto-generated PKs as the 'refresh after insert' settings in an EO work with a RETURNING clause, which is not supported for instead-of triggers. This means we'll have to find the PK sequences ourselves from the EOs and populate these fields ourselves, before committing to the database. So far so good, but things go wrong when we want to insert master and detail at the same time. The PK and FK of the child record are already filled in at insert time (which is nice) but for some reason the child records get inserted before the parents, resulting in an error on the FK as the parent record does not yet exist (which is not nice).
    So, here's the question: is there a way to control the order in which new VO records are inserted ? On what is the default order based (maybe a little renaming could help us out to get the alphabet our way) ?
    We know defining the FKs as 'initially deferred' will make sure they are only checked at commit time, but our DBA prefers to not use that solution unless strictly necessary. (is there anything bad about deferred keys why we should believe him? ;o) )
    And additionally, is there a way around all this manual PK-fetching ? We've tried using the refresh(int refreshMode) method of EntityImpl, but it didn't seem to work.
    Many thanks in advance for your tips, suggestions and solutiosn !
    Best regards,
    Benjamin De Boe

    Benjamin,
    To handle the problem with the child/parent records being inserted in the wrong order - have a read of the Oracle ADF Developer's Guide for Forms/4GL developers, section 26.7. I use that technique with great success.
    John

  • Is there a way to change the order in which iTunes searches for new podcasts?

    When I tell iTunes to update podcasts, it searches for them in the order that I have subscribed to them. However, most of my favorite podcasts I've started listening to only very recently, so on a day with a large number of new podcasts I have to wait for a few minutes before iTunes even detects and places them on the "downloading" queue. The sheer number of podcasts I am subscribed to makes unsubscribing from all and then resubscribing in a more optimal order thoroughly unpleasant. Is there a way I can reorder the priority queue for checking for new podcasts, so that I can click 'refresh,' grab my favorites right away, put them on my iPod Shuffle, and the leave the rest to download?

    I'm not sure, but I think the change was using the font "Segoe UI" instead of "Tahoma", and maybe, Lucida Grande.
    I haven't tried it, but I assume you can edit the fonts, which are specified in (basically) a text file (at least, for iTunes 10).
    Make a backup of the file before you edit anything (or you can repair/reinstall if you mess it up). See the following post for some more info:
    http://discussions.apple.com/message.jspa?messageID=12226047#12226047
    You'll want to edit the "font", not the "xp-font". I can't tell you what fonts will work.

  • How can I change the order in which my Yahoo BT m...

    Hi ....I am a complete computer idiot and  I would like some advice please.
    Emails in my Yahoo BT 'in' and 'sent' sections used to be listed with new mail at the top...ready to be opened and earliest at the bottom.
    For some unexplained reason recently  the order has  suddenly reversed.
    It is very annoying as I now have to scroll down to open any new mail or any mail recently sent .
    is there any way I can reverse this back tohow it was.
    I cannot find any answers anywhere?
    Help please!

    I just checked BTYahoo mail via webmail and those headers don't seem to be there. I had to go into the spam folder though coz I use a mailer.
    My God it's a jungle in the spam folder !!
    If he's using a mailer.. ie: Outlook then, as said, just click the bar that has date, or sender on it.
    An MSCE in computing is like having a McDonalds Certification in World Cuisine, pointless.

  • How does one change the folder to which scanned images are saved?

    Using a CanoScan 9000F Mark II scanner
    Using the ScanGear driver software that came with it
    Right now every time I scan something, it is automatically saved in "My Documents", and I have to drag and drop the file where I really want it to go. How do I change it so that the file is saved where I want it to go in the first place. Also, it is automatically assigning a file name so that I have to go to the file and change that to what I would like it to be too. How do I make it so that I can name the file before it gets saved. Neither do I see where it gives me the option to choose the format in which the file is saved; it is saving the files automatically as JPG, but I would like to save them as TIFF or BMP.
    These seem to be very standard options; so I don't know why I'm finding it so hard. I must be blind or something.
    Thank you for your time and assistance.

    Hello barbarossa,
    Great question!  You can change all these settings through the My Image Garden software.  The exact procedure will vary depending on the version of Windows you are using.
    If you are having any difficulty locating this software, feel free to visit the link below to let us know your operating system and we can follow-up with step-by-step directions.  Thanks! 
    http://www.usa.canon.com/cusa/consumer/standard_display/contact_us_consumer
    Did this answer your question? Please click the Accept as Solution button so that others may find the answer as well.

  • How do I change the address from which voice memos are being mailed?

    My wife's iphone is sending voice messages with my return address. I can't find the setting to change that. Ideas?
    Thanks,
    Bob

    http://support.mozilla.com/en-US/kb/Changing+the+e-mail+program+used+by+Firefox

  • What determines the order in which phone numbers are displayed in address book/contacts on Mac and iPad/iPhone?

    I may have "Work, Home, Skype, Work Fax" (for example) order in Adress Book on my Mac, but there is no gurantee, apparently, that this order will be preserved across entries on my iPad and iPhone.  In some entries I might get "Home, Work, Skype, Work Fax" while others might have "Work, Skype, Home, Work Fax".  Even with just Work and Home, the ordering is not consistent.  Can I force a specific order?

    Having the same problem.  Have iPad and iPhone, both running ios5, both sync to the cloud, and data entered on one soon shows up like magic on the other.  But Lion MacBook Pro refuses to join in the dance.  Contacts and calendar entries on the mbp don't show up in either the ipad or iphone.  I have the same account login info setup on all three devices, and as much as I can tell, preferences set up correctly.  Oddly enough, when I am in the mbp cloud preference pane, and click on the ? for help, it tells me it can't give me help because it is not connected to the internet.  Well, it clearly IS connected to the internet.  Don't know if that is related to the non-syncing or not, but it is a little strange.  A little bit of operating manual for cloud would be helpful.

  • How can I change the order in which my shared video podcasts are listed?

    I go into front row, video, and then access the shared video on another machine. Under that menu I have a video podcast option and then under that the list of my actual podcasts.
    The list seems to be ordered alphabetically by title. I'd rather order the list by date. Since they are podcasts. And they are usually date oriented.
    The bizarre default ordering when combined with the fact that not enough of the podcast title is shown makes it impossible to find anything through this interface. At least if it were ordered by date, I'd have a chance to get to the new or old stuff.
    Anybody know how to change this?

    not really solved. just cleaning up my list of unresolved questions.

Maybe you are looking for

  • MC.9  drill down at storage location level

    In mc.9  report  stock against plant xxxx  at storage location drilldown I see In total  valuated stock is 0 But at storage location 0040 I see  423.686 as valuated stock and at storage location 5M06 I see  minus 423.686  as valuated stock Client nee

  • Carry Foraward of AA Balances

    Hi, We have changed the fiscal year of FI-AA  to 2009 in t-code AJRW,  but some assets showing as error in Fiscal Year Change. and balances of those assets were not carry forwarded to FY 2009. i have also run the programme AUVA to complete the assets

  • Report which shows Transaction code for each company

    Hi Experts There is a requirement for a report which must display the following Parameters Tcode : S_ALR_87013340 User       Tcode                         Description      Profit Center         Profit Group     MEND    S_ALR_87013340      XXXXXXXXX  

  • HT5037 Running in circles

    I have an older iPhoto library saved on an external HD. I tried to run the iPhoto upgrader on the old iPhoto library. After routing that library, my MBA tries to open the library in my new iPhoto, but it still says I need to upgrade the old one. Now

  • Flash file components

    Hello, After affects has a feature where you can export a document with all the files associated in your scene. Is that possible (or something like it) in Flash CC? Thanks in advance