Document ordering in attachment tab

Hi all,
I am a bit confused about the ordering of document in attachment tab of livecycle.
My customers ask for a chronological order of document when they add attachment from the workflow. I think the easiest way to do is use a list of document, and add new document at the end of the list whenever it is added, but LiveCycle seems to display them in very strange order.
My scenario is:
LCES process adds 5 documents in the attachment list. (it adds 1 document at first task, 2 at second task and the last 2 documents at the third task)
I create following variable:
- attachmentList: List of <document> (to store and display in attachment tab)
- tempDocument: document (to store generated pdf here and add it into attachmentList)
- genCounter: int (to differentiate if user generate pdf many times)
After generate the pdf, I call a execute script similar as follow:
=====================================================
import java.util.List;
import java.lang.String;
import com.adobe.idp.Document;
import java.io.File;
Document doc =  patExecContext.getProcessDataDocumentValue("/process_data/@tempDocument");
int genCounter = patExecContext.getProcessDataIntValue("/process_data/@genCounter");
File file = new File("finalDisbursementLetter"+genCounter+".pdf");
doc.copyToFile(file);
Document doc1  = new Document(file, true);
List list =  patExecContext.getProcessDataListValue("/process_data/attachmentList");
list.add(doc1);
=====================================================
The order of file being added is (top to bottom):
[1]
GrantApplicationForm.3214.pdf
draftDisbursementLetter1.pdf
draftPaymentVoucher1.pdf
finalDisbursementLetter1.pdf
finalPaymentVoucher1.pdf
but when I see in the attachment tab, the order is:
[2]
GrantApplicationFormFTS000908000017.3214.pdf
draftDisbursementLetter1.pdf
finalPaymentVoucher1.pdf
finalDisbursementLetter1.pdf
draftPaymentVoucher1.pdf
I have tried with a custom component to list the file name, it still display correct order, i.e. as [1].
Do I miss out any thing or can you let me know what ordering of attachments that Livecycle is using?
Thank you,
Anh
P.S.
When it first add 3 document, i still see it displays correctly. i.e.
[3]
GrantApplicationForm.3214.pdf
draftDisbursementLetter1.pdf
draftPaymentVoucher1.pdf
But when adding 2 more documents, the ordering is very strange as [2]

I tried to download the 5 documents and try sorting with windows, i realized that if I download 1 by 1 by the order:
GrantApplicationForm.3214.pdf
draftDisbursementLetter1.pdf
finalPaymentVoucher1.pdf   
finalDisbursementLetter1.pdf
draftPaymentVoucher1.pdf  
and sort by accessed time, I will have the order as [2].
i.e.
GrantApplicationFormFTS000908000017.3214.pdf (6:58:18/6:58:18/6:58:46)
draftDisbursementLetter1.pdf (6:58:18/6:58:25/6:58:25)
finalPaymentVoucher1.pdf    (6:58:18/6:58:28/6:58:28)
finalDisbursementLetter1.pdf (6:58:18/6:58:30/6:58:30)
draftPaymentVoucher1.pdf    (6:58:18/6:58:32/6:58:32)
The timing are created/modified/accessed in order.
I don't know why it sort by accessed time or it is just a coincident ...
Regards,
Anh

Similar Messages

  • Attach doc thru program in  the Attachment tab of Transaction CRMD_ORDER

    Hi,
    Does Anybody worked on the below scenario.
    in the Transaction CRMD_ORDER i need to attach the document of HTML file (which the data is coming from Some other
    tool in a background).my requirement is to attach the document in the attachment tab in through the program.
    Thanks,

    Hi,
    U can use methods in the class CL_CRM_DOCUMENTS to attach files to CRMD_ORDER.
    Let me know if it helped.
    Thank you,
    Binno Don Thomas

  • Sending Mail with attachment and preserving the order of attachment

    Hi Everyone!!!!!!
    My requirement is to send Email with attachment in the same order as they were attached by Sender while composing the mail. I want to preserve order of attachment in the mail and when receiver open a mail, the attached files should be reflected in same order as it was on sender side. In my application,the documents being upload are already in my database. So, user just requires to mark the corresponding check box and enter the Sequence number for each attachment. When he clicks on "SEND" button, the Source file is first written from database to OS level and then files are attached from source available on OS . The attached file name could be anything. Based on the Sequence number file should be attached and send. My current code works fine,but problem it is that the Sequence number is not preserved in my attachment . However, when I traced the output of FOR Loop by inserting it in a table " temp_trace" I found that the Sequence is preserved in the order that I want. So, I think that uploaded files are written on the Operating system in same order but they are not attached in same order. Below is the sample code that is I am using to attach file in email. Here, the user_sequence is the sequence number entered by user.
    for i in (select case when user_sequence is not null
    then trim(to_char(user_sequence ,'09'))||'_'||file_name||'.pdf'
    else ||'_'||file_name||'.pdf' end file_name ,
    file_src,length(file_src) len,cd.doc_id,PRIORITY from
    MIM_CLIENT_DOCS CD,(select DOC_ID ,user_sequence from table P_DOC_AND_user_sequence ) TEMP_TAB
    WHERE CD.DOC_ID = TEMP_TAB.DOC_ID order by case when user_sequence is null then 1 else 0 end, file_name)
    loop
    insert into temp_trace values(i.file_name);
    L_OUT := UTL_FILE.FOPEN(v_oracle_dir,i.file_name,'wb',32760);
    end loop;
    I want my output as
    1_first attachment.txt
    2_second_attachment.docx
    3_abc.sql
    _xxx.txt  ------------------ When sequence is not assigned by user That is null at last.
    Unfortunately, I am not getting attachment in mail in this sequence. Can anyone give me suggestion.
    Sorry for stuff essay and thanks in advance!!!!!!!!!!!

    >
    Please update your forum profile with a real handle instead of "974850".
    My requirement is to send Email with attachment in the same order as they were attached by Sender while composing the mail. I want to preserve order of attachment in the mail and when receiver open a mail, the attached files should be reflected in same order as it was on sender side. In my application,the documents being upload are already in my database. So, user just requires to mark the corresponding check box and enter the Sequence number for each attachment. When he clicks on "SEND" button, the Source file is first written from database to OS level and then files are attached from source available on OS . The attached file name could be anything. Based on the Sequence number file should be attached and send. My current code works fine,but problem it is that the Sequence number is not preserved in my attachment . However, when I traced the output of FOR Loop by inserting it in a table " temp_trace" I found that the Sequence is preserved in the order that I want. So, I think that uploaded files are written on the Operating system in same order but they are not attached in same order. Below is the sample code that is I am using to attach file in email. Here, the user_sequence is the sequence number entered by user.Always post code using <tt>\...\</tt> tags as described in the FAQ.
    for i in (select case when  user_sequence is not null
    then trim(to_char(user_sequence ,'09'))||'_'||file_name||'.pdf'
    else  ||'_'||file_name||'.pdf' end file_name ,
    file_src,length(file_src) len,cd.doc_id,PRIORITY from
    MIM_CLIENT_DOCS CD,(select DOC_ID ,user_sequence from table P_DOC_AND_user_sequence ) TEMP_TAB
    WHERE CD.DOC_ID = TEMP_TAB.DOC_ID order by case when user_sequence is null then 1 else 0 end, file_name)                               
    loop
    insert into temp_trace values(i.file_name);
    L_OUT := UTL_FILE.FOPEN(v_oracle_dir,i.file_name,'wb',32760);
    end loop;I want my output as
    1_first attachment.txt
    2_second_attachment.docx
    3_abc.sql
    _xxx.txt  ------------------ When sequence is not assigned by user That is null at last.
    Unfortunately, I am not getting attachment in mail in this sequence. Can anyone give me suggestion.I see no code that attaches anything to email messages. What code is used to do this? Why are the files being written to the file system?

  • Purchase order Condition control tab?

    Hi,
    Here in the purchase order condition control tab I need to get Price Date and Price date category. Presently they are not appearing in my purchase orders. When I go to screen layout, I am not able to get those fields to configure.
    Could please anybody help me urgently?
    Thanks,
    Bhairav

    Hi
    GOTO----> OLME--> PO -> Define Screenlay out at Document level -> There Choose your Field Selection ( NBF  and ME21N)... and go into to details--> And select the field selection group  Quantity and Price and Double Click--> There you choose the field  <b>PRICING DATE CONTROL</b>    and  Check it as a Required Entry or Optional Entry and save . <b>DO IT FOR BOTH NBF and ME21N FIELD SELECTION.</b>
    Now when ever you make PO in ME21N.....You will get Pricing Date Category and  Price Date Fields in  PO-> Item Details---> Condition Control Tab.
    Reward if useful
    Regards
    S.Baskaran
    Message was edited by:
            baskaran srinivasan

  • Subsinvprocess in the sales order header --- billing tab and in the custom

    Hello All
    there is a field SubsInvProcess in sales order header - billing- tab and in the customer master - billing tab
    what was the functionality of this field. I never worked with it
    kindly help on this one. 
    Thanks,
    prasad

    Dear Vara prasad,
    The value of this field is if you want to print the invoices that are being posted manually you can activate this field.
    It will be directly proposed from customer master to sales document, where you can change.
    Please let me know if you want any further clarifications.
    Please go through this thread also for further reference.
    Clarification for usage of Subsequent Invoice Processing in Customer Master
    Thanks&Regards
    Raghu.k

  • Sending a document as an  attachement to an email id.

    Hi,
       I have a requirement to send a PDF document as an attachment to an Email Id like [email protected] I have few doubts please can anybody clear my doubts?
    1 . What are the pre-requisites to send a mail to Yahoo or other ids?
    2. Any special configurations need i get from Basis Team?
    3. I am using Function module SO_NEW_DOCUMENT_ATT_SEND_API1.
    4. In the configuration of NACE i have given Medium as Simple mail..
    Regards,
    Sekhar.J

    Hi Sekhar,
    In order to send the mail attachment as PDF file, there is no need for any special configurations to be made.
    What you have to keep in mind is to use the FM "Convert_OTF_2_PDF" before using the FM "SO_NEW_DOCUMENT_ATT_SEND_API1".
    Also, with the document type while building the document data for the attachment,use the doc type as "PDF" instead of "RAW".
    In case you have any further clarifications,do let me know.
    Regards,
    Puneet Jhari.

  • VA01 Sales order - Header-- Accounting tab need to add a field

    Dear All,
    The requirement is,
    1. I need to add a field in Sales order.
    Path for the same is as follows:
    VA01> Goto> Header--> Accounting tab
    2. The field will be a date field that needs to calculate date on.
    a)create a new field. ex - zchdt (chq due date)
    b)when customers enters value in Assignment,
    i.e vbak-zuonr
    after that trigger logic is
    3.vabk-kunnr = knvv-kunnr
    a)sy-date + knvv-kvgr2 (exclude sundays)
    example - 14 sept + 30 days = 14th october
    should populate value - 14th october i.e. field (zchdt)
    4. This activity needs to be triggered before the sales order is saved.
    kindly know whether this is possible or not.
    if possible how & which exit & also with example code.
    if you could give me your contact(cell no).
    Regards,
    Nagendra D.S.
    Mobile - +91 9819899082

    Hi All,
    VA01 Sales order - Header--> Accounting tab need to add a field. field name - zchdt(cheque due date)
    when customer enters value in Assignment i.e zuonr & after that trigger logic is
       1.     vbak-kunnr = knvv-kunnr
       2.     sysdat + knvv-kvgr2 (exclude sundays)
    example - 16 sept + 30days = 16 oct
    in field zchdt value 16 oct as to populate
    Pls help me in the code.
    Regards
    Nagendra

  • Custom field in 'Notes and Attachment" tab of shopping cart

    Hi All,
    I am working in SRM 7.0 classic scenario and i have requirement in which i need to add custom field in 'Notes and Attachment" tab of the shopping cart portal.
    I have added those fields in structure --- INCL_EEW_PD_ITEM_CSF and INCL_EEW_PD_ITEM_CSF_SC.
    Also implemented the BBP_DOC_CHANGE_BADI in while i am populating the custom field value.
    I have created custom field as INPUT FIELD in webdynpro component /SAPSRM/WDC_DODC_NA and view : V_DODC_MAIN_VIEW.
    Now I can see the custom field value in table BBP_PDISC, but i am not getting the value in Shopping cart "Notes and Attachments" tab.( I am able to see the field but not the value of it).
    The value is getting populated in ITEM DATA tab instead.
    Please suggest if i am missing anything in the process and how to achieve this.
    Thank you in advance.
    Thanks,
    Satheesh

    Hi,
    You have done everything.. well.. except that you did not set the attribute of the input field to this value.
    When you have value u just need to bind it using set_attribute method of the element.
    Use  ctr+f7 to generate the wizard .. select in set mode.. click on context and select the attribute that you have created in the context.
    Hope this helps.
    Regards,
    Vinay

  • How do I change the order of open tabs?

    I currently have approximately a dozen tabs open, of which most are required to be viewed in a particular order. Is there a way to change the order of these tabs? If there is not, holding onto one of the tabs without sliding it sideways could become a method of "unlocking" the selected tab, allowing it to be moved up or down the list (I sure think it sounds like a good, and mostly easy, possible future addition to the app).
    Thanks for your time,
    Adam

    Adam, unfortunately at this time this is not a feature of Firefox for Android. To move the tabs you would have to close it out and open them in the order you wanted them to appear.
    If this is a desired feature however, I would recommend leaving feedback about this in input.mozilla.org.

  • Modify Sales order Item additional tab B

    I need to modify Sales order item additional tab B ...by removing the exisitng fields and should add some new fields ....which is ok. But does it have any impact becoz the same screen fields coulbe used in any of the other transaction .......i  just wanted to know if we remove the fields from sale orde item additional tab B and some new details will have some impact

    Hi,
    Before making any modifications check "Where-used". If it is in some other program other than the VA01/02/03, then better consult your lead before modifying.
    If you do not find, go ahead and make the changes confidently.
    Regards,
    Subramanian

  • Need to modify Sales order Item additional tab B

    Hello all,
    I need to modify Sales order item additional tab B ...by removing the exisitng fields and should add some new fields ....does it have any impact on this screen could be used in any of the other transaction .......i  just wanted if we remove the fields and some new details will have some impact
    Regards,
    KK

    Additional data B is used to add your own fields also known as custom fields in sales order.
    Custom fields can be added to tables VBAK & VBAP (depending on header or item). Similarly you can remove fields if you don't require it anymore.
    In short, your requirement can be met but you have to take help of ABAP consultant since it requires maintenance of user exits and modification of screens.

  • How do i make a tab active and make it stay that way always. If i put a website in my home page in order for the tabs to open automatically in that same homepage , this setting is not working, every time I open a tab , a white window appears .

    How do i make a tab active and make it stay that way always. If i put a website in my home page in order for the tabs to open automatically in that same homepage , this setting is not working, every time I open a tab , the window appears white .

    By default Firefox opens a blank page for a new Tab, there is no setting to change that action without installing an add-on.
    New Tab Homepage extension: <br />
    https://addons.mozilla.org/en-US/firefox/addon/777

  • I received a .pdf document as an attachment to an Entourage Email. It refuse to print on my HP4050N printer which is otherwise performing as advertised. Printing fron the desktop, Adobe 9.4.4 nor Preview won't work. I have a PowerPC G5, OS 10.4.11.

    I received a .pdf document as an attachment to an Entourage Email. It refuse to print on my HP4050N printer which is otherwise performing as advertised. Printing fron the desktop, Adobe 9.4.4 nor Preview won't work. I have a PowerPC G5, OS 10.4.11.

    I think the file has somehow been corrupted. Can you have the person that sent it to you send another copy?
     Cheers, Tom

  • I've been sent a scan of a document as an attachment. Clicking on it, I get the message, "Pixel aspect ration correction is for preview purposes only. Turn it off for maximum image quality." What is pixel aspect ration and how do I turn it off?

    I've been sent a scan of a document as an attachment. Clicking on it, I get the message, "Pixel aspect ration correction is for preview purposes only. Turn it off for maximum image quality." What is pixel aspect ration and how do I turn it off?

    It's "aspect ratio", not aspect "ration". 
    It's what determines whether you have square pixels ("normal") or, if rectangular pixels, what the aspect ratio (width : length)  of that rectangle is.
    It's explained in the Help files.  I cannot go into more detail because you have neglected to provide information about your platform and exact version of Photoshop.
    Example in next post

  • How to change the order of the tabs in featured news?

    Hi,
      I use the 'Featured News' widget on my company website and it has 10 tabs. The newest item is at the top but when I add a new tab it goes to the bottom and I can find no way of changing the order of the tabs so that everytime I add new news I have to copy each tab and it's content down one place in order to get an empty tab at the top to put the new news item in. This takes an unneccesssarily long period of time. Can someone please let me know if there is an easy way to change the order of the tabs?
      Thanks very much ;0)
            Justine

    Just click on the title tab until it is isolated (one click before the text is highlighted) and move the tab to the position you want.
    Thanks for your reply. I've done this in the past but found that the position of the tab in terms of it's place in the hierachy doesn't change so if I move the top tab down one, the way you've described and then upload the page I find that the second tab down (which was the first previously) displays first. How can I change the 'position of the tabs interms of their hierachy in the widget?
      Thanks again
         J

Maybe you are looking for