Why setAttribute not in correct order?

Hi All,
I just got a question, why the setAttribute method generate a wrong order of attributes. In my following fucntion, suppose the name attribute is first created, but when I check my xml file, it becomes the 2nd attribute.
any mistakes in my code?
public void SaveXmlNode(Document doc, Element parentNode)
        Element rootElement = doc.createElement("People");
        rootElement.setAttribute("Name", this.name);
        rootElement.setAttribute("Sex", this.sex);
        rootElement.setAttribute("Phone", Integer.toString(this.phone));
        parentNode.appendChild(rootElement);
    }

Sure, just read the XML file as a character string and use something like regular expresions to locate the attributes. Then you can arrange them any way you want.
But, if you want XML-aware methods, they will constantly frustrate you because they will never do what you want with the sequence of attributes.
Dave Patterson

Similar Messages

  • PO screen custom fields are not in correct order

    Hi Experts,
    After creating Shopping cart and purchase order successfully created.
    Added my custom fields for PO structure INCL_EEW_PD_ITEM_CSD_PO fields are visible in PO screen automatically with out adding my custom fields in PO layout /SAPSRM/WDC_DODC_PO_I_BD
    when i go to PO screen i can see my custom fields but all fields are not in correct order.How can my fields should be in order.
    and i added two custom buttons in my PO layout for WD component /SAPSRM/WDC_DODC_PO_I_BD i am not able to see my buttons?
    Could you please help me out in this issues its urgent.
    Thanks,
    Venkatesh G

    I've had this problem. There may be a more elegant solution, but what I do is make a playlist of the album and put the movements in the correct order in the playlist. I've also put numbers (01, 02, etc.) in front of the name of the movements. Either one works.
    Hope this helps.
    Ben

  • BEx variables not showing correct order despite ordering at query level

    Dear Experts,
    I am using a workbook with 2 queries sharing same variables.
    The Queries variable order for display in the popup screen has been re-arranged at Query designer level (query properties > variable sequence). Regenerated queries. Relogin to BEx . Re-run workbook. Same old order.
    Please advise what could be the cause. I am also wondering if this is due to personalisation.
    regards
    Bass

    Hi Bass,
    You mentioned workbook.
    If the query itself also has this problem, it can be a bug as SAP Note 1568815.
    Symptom
    The sequence of the variables in the variable screen is lost.
    You may implement the correction of this note via transaction SNOTE if the SP of your system fits.
    After that, you need to regenerate the query in RSRT.
    Regards,
    Patricia

  • TS3322 Photos do not appear in order on apple tv

    Synced photos do not appear in order when viewed on apple tv.  Shuffle is turned off, have downloaded photos from 2 cameras on computer & saves them in folder, renamed them so they are in correct order but when viewed on apple tv they are not in correct order.  Have tried renaming them numerous times & they are not in correct order.

    This used to work properly till Nov 2012.
    After I upgraded to Ios 6.0.1, this has stopped working

  • Why does Ipad not keep photos in there correct order ie: img_001, img_002 an so on even though thats the way they are in the folder

    The folder that they are in is in the correct order but when i add them to Ipad they are all mixed up.  This is so annoying when i am trying show someone there Wedding Album in the correct order

    From http://support.apple.com/kb/HT4221 for iOS 5 :
    If you are not using iPhoto or Aperture on Mac OS X, and if your device is using the latest software, it sorts photos in ascending order by the Date Modified.
    So you will need to amend the date modified field on your computer and re-sync to get them into the order that you want - or use a third-party photo management app instead of Photos e.g. Photo Manager Pro which allows more control of your photo sorting within it e.g. by name, size, date, or you can drag them into a different order

  • Why exchange rate is not displayed correctly when I create the PO in SRM?

    Hi Gurus,
    Yesterday I insert a new row at OB08 tx. at backend system (R/3) for exchange rate of May 17,2010, the value was 10.00. Then I run the BBP_GET_EXRATE program to replicate the info to SRM.
    But when I created a purchase order (PO) the value was 12.24 for exchange rate (this value 12.24 is the value for the previous day May 16, 2010).
    Today morning (May 18, 2010), I inserted another row at R/3 and replicated to SRM, the new value for May 18 was 11. I create another PO and the value was 10 for exchange rate (the value for yesterday).
    But when the PO is transmitted to R/3, the exchange rate is the correct.
    My question is: Why exchange rate is not displayed correctly when I create the PO in SRM? Exists an aspect of memory in SRM that it has to be refreshed? Why SRM is getting the exchange rate for yesterday? Is an issue for time zone?

    Hi Muthu,
    I'm in Extended classic.
    I already discovered what is happening. At the time of being creating the purchase order (PO), it takes the exchange rate of the delivery date of the shopping cart (SC). But when the order is authorized and tries to transmit it to R/3, it takes the exchange rate of the date of creation of the PO.
    Two checks of budget exist:
    1.- When creating PO (exchange rate date of delivery date of the SC's item)
    2.- When authorized and tries to transmit it to R/3 (exchange rate date of creation date of the PO)
    If exchange rate of delivery date of the SC is lower than exchange rate date of creation of the PO, there are cases in which it is marking budget error.
    Now my question is: It is a standard behavior? (to take different exchange rate)

  • Playlist's not in the correct order

    I've always had a last played list of all the songs I've listened to recently. Ever since the new itunes update when I update my iPods (shuffle, nano and iphone 4S) they are in alphabetical order but in the smart playlist on my computer they are in the correct order. What is going on that the order of the music is incorrect? Is there a simple fix for it or is it just a glitch? I have seen other questions that are sort of like mine, however, they are not completely like my situations so I wanted to ask specifically for my situation. Thanks in advance!

    Just to be clear, on all your music playlists, if you click on a playlist to view the songs it will show them in alphabetical order.
    HOWEVER, IF YOU DO NOT ENTER THE PLAYLIST TO SEE THE SONGS BUT HIT PLAY ON THE PLAYLIST ITSELF IT WILL PLAY IN THE ORDER ON WHATEVER ITUNES YOU ARE STREAMING FROM.
    I have seen alot written about the "playlist bug" but its not a bug. It works.
    However, I suspect the ATV shows the songs in order for two reasons:
    1) Apple assumes if you have a playlist, you will manage it from your iTunes and thus you will simply hit play on the Playlist to play it in order per my comment above. Thus, when you enter the playlist, Apple is using what it things will be the easiest default method for finding your songs which is alpha. Why do this? Because again assuming they arent expecting you to enter the playlist except to either find an album or artist, this would be the easiest way to do this and then from there they assume you may want to find other songs or albums or create a genius playlist from this artist hence why you can hold down the play button and get those options.
    2) This is version 1 of the software and as we know with apple its not throw in all bells and whistles but streamline and simple. Even if it means locking things down like being able to resort a playlist on the AppleTv
    I dont necessarily agree but it makes sense if you view it that way and also understand that Apple looks at this new gen of appletv as a streaming device not as a device to manage your content.

  • ACL does not correctly order the permissions when they are updated

    Outlook Connector sjab32.dll 7.1.228.0 sjms32.dll 7.1.228.0 sjui32.dll 7.1.228.0 sjtp32.dll 7.1.228.0
    Problem: We have identifed an issue with editing calendar permissions using the Outlook Connector. Basically the calendar ACEs are evaluated on a first match basic. Outlook Connector does not correctly order the permissions when they are updated. A brief example is below. Editing permissions via UWC works fine and will in fact fix any out of order ACE entries.
    Basic calendar permission:
    1.aces=@@o^a^rsf^g;@@o^p^rw^g;@@o^c^wdeic^g;@^a^sf^g;@^c^^g;@^p^r^g^
    after adding user mab, Ace has now been re-ordered so that the everyone permissions are now before the owner permissions:
    2.aces=mab^p^r^g;mab^c^rwd^g;mab^a^rsf^g;@^c^rwd^d;@^c^^g;@^p^r^g;@^a^sf^g;@@o^c^wdeic^g;@@o^p^rw^g;@@o^a^rsf^g
    any suggestion as to why this re-ordering is happening when updated through OC and any supporting doucuments for ACL

    Hi,
    This issue is most likely related to bug #6471869 (Outlook Connector allows invites to users with restricted permissions). This has been fixed in the latest Outlook Connector 7.1_233 (aka 122018-09). I recommend logging a Sun support case to get a copy of this new release.
    Regards,
    Shane.

  • My iPod touch is not playing the songs on the playlists in the correct order. Can anyone help?

    My ipod touch is not playing the songs on the playlist in the correct order.

    You can redownload most iTunes purchases by:
    Downloading past purchases from the App Store, iBookstore, and iTunes Store         

  • SSRS report not displaying data in correct order

    Guys,
    I have a SSRS 2012 report not displaying returned records from SQL in the correct order.  Running the stored procedure in SSMS and supplying the parameter values returns the data correctly and running Query Designer in SSRS using the stored procedure
    on the dataset in question, likewise returns the data correctly.  Only when I run the actual report does the data display incorrectly(always last name order).  I've done similar reporting using very similar stored procedures and I've never had this
    problem.  Below is the stored procedure.  "@SortBy" is the parameter with the sorting value. 1=Due Date; 2=Denial Amt and 3=Last name and is passed by SSRS to SQL.  Wish I could supply screen shots.  
    Thanks for any help,
    Dave
    ALTER PROCEDURE [dbo].[RAC_PT_List]
    @Level as int,
    @SortBy as int,
    @PTLName as varchar(30) = NULL,
    @User as varchar(10) = NULL
    AS
    SELECT pat.headerID,
    pat.PT_LName + ', ' + pat.PT_FName AS PTName,
    pat.PT_AcctNo,
    rco.RCO_CLMREF,
    rco.RCO_AppealLevel,
    rco.RCO_LevelNo,
    rco.RCO_AuditorStatus,
    let.LET_DEN_DueDate,
    CONVERT(varchar(12),let.LET_DEN_DueDate) as DueDate,
    let.LET_DEN_Dollars,
    let.userID
    FROM Master_PT_List pat
    INNER JOIN Master_RCO_Work rco on RCO.PT_headerID = pat.headerID
    INNER JOIN Master_Letters let on LET.PT_headerID = pat.headerID
    WHERE (@PTLName IS NULL OR(pat.PT_LName LIKE + '%' + @PTLName + '%'))
    AND (rco.RCO_LevelNo = @Level)
    AND (let.userID = @User)
    --AND (rco.RCO_AuditorStatus <> 'Closed' and rco.RCO_AdminStatus <> 'Closed')
    ORDER BY 
    CASE WHEN @SortBy = '1' THEN LET_DEN_DueDate
    END
    DESC,
    CASE WHEN @SortBy = '2' THEN let.LET_DEN_Dollars
    END
    DESC,
    CASE WHEN @SortBy = '3' THEN pat.PT_LName
    END

    Hi DaveMac1960,
    According to your description, when you render data in report, you find it always shows the data with unexpected order. Right?
    In Reporting Services, if we don't set any sorting in tablix, it will order the data as your query in SSMS or Query Builder. In some scenario, for example, we add parent group for data rows, it will have the rows sort by the group on data field by default,
    and the "order by" in your query will be ignored. So please check the Sorting tab in Tablix Properties, in this scenario, we suggest you delete any sorting in the Sorting tab so that the "Order By" clause can work.
    Reference:
    Sort Data in a Data Region (Report Builder and SSRS)
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou

  • Why is my .psd file not rendering correctly in ae

    Some layers of the .psd document are not rendered correctly. However they are imported.
    The strange thing is that when I first move from Photoshop to Illustrator, save it as an .ai file it is rendered properly (in Ae).
    I am kind of clueless as to what is causing this issue.
    Kind regards,
    Jelle

    Okay if more information is needed, i'll provide. However you may disregard my initial comment about illustrator. It flattens the photoshop layers so I do not have any flexibility in After Effects. In other words, my main question remains: why is my psd file not rendering correctly in ae?
    Further details:
    -photoshop cc and after effects cc.
    -macbook pro retina
    If still not clear enough, please tell me what details you are looking for furthermore

  • Profit center not picking correctly in PO from sales order

    Hi Experts,
    Profit center is not picking correctly.. in PO
    In material master Profit center is configured as XXXX
    We have raised a sales order for the same material with two line items (e.g) 1500 kgs & 1600 kgs and profit center has been changed in the sales order to YYYY
    There is one purchase requistion for the same material with two line items
    But  we have raised two purchase order for each line item in which the same sales order is linked to these two purchase order.
    In the first PO , for the first line item in sales order ie., 1500 kgs profit center is picked from the sales order ie, XXXX which is correct but  in the second PO, for the second line item in sales order ie., 1600 kgs profit center is picking as YYYY ie which is configured in material master.
    What could be reason ? Help  in this regard will be highly appreciated.
    Thanks in advance
    Narayanan

    Hi Narayan
    Check the Account assignment in the 2nd PO.. Does it have E as Acct Assgn Category?
    It should have sales order as the account assignment... If yes, then it must pick up PC from the sales order...
    Try to put a deletion flag to this PO and create a new one, if possible... You would come to know if some one has changed the PC
    BR,Ajay M

  • Sometimes when I play songs in Itunes by double clicking on them, Itunes will place the song as the first one on the album.  It will chnage the order of the songs on the album, and I can not switch them back to the correct order.

    Sometimes when I play songs in Itunes by double clicking on them, Itunes will place the song as the first one on the album.  It will chnage the order of the songs on the album, and I can not switch them back to the correct order.  This onloy seems to happen when I double-click on the song to play it in itunes.  If I just hit play, this doesnt happen.  As a result, I have several albums now in which the songs are in the wrong order.  Its very frustrating, as this error then transfers over to my ipod every time I sync it.  When I choose the info. for the songs, it has them correctly listed (i.e., it lists the songs as being #1 of 19 on the CD, for example).  But then the song will have placed by Itunes as #5 of 19 for whatever reason.  Itunes does not do this every time, but does it with enough frequency to be maddening.  Any thoughts?

    The problem of tracks becoming de-linked between iTunes and the music files in your iTunes music folder happens for different reasons - this seems to come up fairly commonly in this forum.
    The solution can be to locate each song in the iTunes library, as you mentioned - or, but wait, before I get to that...
    trouble finding the original track in your iTunes music folder? maybe look for it under compilations, or if not using the 'group compilations preference' then look in the folder under the songs artist name, but what song artist name iTunes uses depends on what you have in the metedata tag spot for album artist or song artist. Any varyation in artist name spelling, in the menu item 'get info' metadata for any selected individual track will cause iTunes to create that as a separate artist folder in the library, even names like 'various' or any difference at all (even the word 'the' can change where in your iTunes music folder a track gets placed by iTunes). You can try to use the finder function of find file (finder munu item outside of iTunes) to locate hard to find items.
    Back to how to re-link any de-linked tracks .
    There may be scripts that can help re-link de-linked music files - or, at least provide you a list of such files, Scripts are easy to install and use...
    at Dougs Scripts, there is one called iTunes Track CPR that might work
    http://dougscripts.com/itunes/scripts/ss.php?sp=itunestrackcpr
    or, if you just want a list of de-linked tracks, go to
    http://dougscripts.com/itunes/
    and find the script called List MIA's, this will create a text file listing all de-linked tracks
    if you review the thread at
    https://discussions.apple.com/thread/3633708
    also the thread at
    https://discussions.apple.com/message/17513078#17513078
    you may find more insight into dealing with this kind of issue there, although some of that thread may not apply to your case, aspects of it might help.
    Good luck.

  • HT1040 why can i not seem to order more than one print at a time, which obviously becomes expensive with the shipping, it does not seem to offer me the facility to choose again?

    why can i not seem to order more than one print at a time, which of course becomes expensive with shipping, it does not seem to offer me the facility to choose again? either order or cancel!

    make an album containing the photos you wnat to print, select all photos in the album  and order
    LN

  • My ipod is not playing the correct order of my songs in playlists

    my ipod is not playing the correct order of my song order in my playlists.  it plays random order of playlist songs

    You may have tapped the Shuffle button (looks like two arrows crossing path) in Blue.  Tap it once again to turn it off.

Maybe you are looking for

  • Microsoft.XMLHTTP with C at a flights Database

    In Oracle DB there's a way to convert XML file, and to do it with C++ ? I need to get DB of flights, I've checked a site with data on flights to israel from company named ARKIA and in the source code it says "Microsoft.XMLHTTP". means I can talk with

  • Get The Previous Six Weeks in Query

    I have an MDX query that I'm using in an SSRS report. The report returns results for the current week beginning on Sunday. THe query takes three parameters: Year, Month, and Week. The year is defaulted to the curret year, the month is defaulted to th

  • Business System with or without Party

    Hello, I've a interface RFC to JDBC syncrhonous I've two CC sender (RFC) for the same interface, one for each client. The test for one client is ok however the test in other client result with the follow error: 'aternativeServiceIdentifier: party/ser

  • GetELResolver on managed bean

    I have a trouble using the following code:                if(paramId==null || paramId.equals("")){                     resultadoTesis = (ResultadoTesis)contexto.getELContext().getELResolver().getValue(contexto.getELContext(), "#{resultadoTesis}", nul

  • How to display different headings in list form using "hide content" in SPD 2010

    I built a custom list form in SPD, and applied conditional formatting in some rows Now I like to display different headings (above the 1st row of the form), based on the same condition: e.g. when Status=available, display the heading "SIGN OUT"  (as