Page count  dynamically in adobe forms

Hi,
There is one requirement where they need to print number of pages based on data flow in internal table. to understand better the requirement here is one example as below:
for ex; there is one internal table in one page which has 1000 records, the internal table is designed on body page (Design view), on the same page there is one footer which say the current page number based on internal table data. say for ex:  the internal table filled with 100 records in the first [page then it should print page count 1 then the remaining 900 records it fills the second page then it should print on the footer page count 2. similarly for last page  it should print page count 10.
Note: 1  there is other master pages also but the counting of pages should be for dynamic data in the internal table.
Note: 2 the actually counting should start with value 2 initialization . means first page count should be 2, 3, 4, ... 11.
solution: do we need to write some code in the script. If yes please provide the code or is there any way to set the page count for that variable from that point onward with +1 page.
Please advise. Your answer will be highly appreciated.
Thanks,

Hi,
Could you please explain me where I need to write this piece of code in script editor on design view or in master page. I had already written a code on for that variable on master page layout:ready
data.#pageSet[0].NEG_PROD_FLOW.LINES.Subform6.PAGES_TEXT.GV_PAGE_COUNT2::ready:layout - (FormCalc, client)
form.NEG_PROD_FLOW.LINES.PAGES_TEXT
this.rawValue =  xfa.layout.page(this);
this.rawValue =  (xfa.layout.pageCount() - xfa.layout.pageSpan(form.NEG_PROD_FLOW.LINES.PAGES_TEXT));
but i need to start page count initialization with value 2. the first page should display 2
is that possible to do that.
please advise.
Thanks,

Similar Messages

  • Dynamic row counter column in Adobe Forms

    Hi Guys,
    My table in Adobe Forms is dynamically created with Conditional Breaks. I want to display 1st column as Sr.No. displaying row counter for tables on each page.
    Anyone have idea how to achieve the same.
    Sr.No
    Name
    Address
    1 (generated in adobe forms dynamically)
    xyz
    awsaxa sadsad
    2 (generated in adobe forms dynamically)
    abc
    asds  sad ads
    so on......
    Regards,
    Naveen

    Hi Guys,
    Not able to find any counter variable for table. So what I did is inserted the counter logically before calling Adobe forms driver program.
    FYI.
    Regards,
    Naveen

  • 'Submit' on dynamically generated adobe form

    Hello,
    I have a dynamic adobe form, which at run time generates the pages based on certain conditions. There are 3 sub-forms whose visibility is controlled via javascript ( again based on condition ). At run time, at once, one page can hold either of these sub-forms. This is an offline scenario and i have the submit button always coming up at the last page.
    The issue is that,  when i click on 'Submit' only the data in the last page gets picked up for the web service. The data in the previous pages are not being picked up.
    For ex : say Page 1 has sub form A
                       Page 2 has sub form B
                       Page 3 has sub form C,
    the data in Page 3 alone is getting submitted.
    However, if i generate the form only for A / B / C, (only one page scenario ) it works fine. The issue is when more than one page is generated.
    How to make the submit button function across all the pages?
    kindly help.
    Regards,
    Ashwitha

    Hi Anantharam,
    Please create and action in your view and attach it to your Interactive form UI element's onSubmit event. By doing this, whenecver you press the Submit button in the form, this action will be invoked. You can place any methots/code that you want to execute on click of submit button.
    If you are using the button outside the form, then you try printing one of the values that you filled in the form which is binded to context. This way you can test.
    If you are using WDP activex UI element s in the form then you need to have ACF installed on the machine and also ensure that the displayMode property of Interactive form is set to ActiveX.
    Hope this helps!!
    Regards,
    Arafat

  • How to add another row dynamically in Adobe Forms ?

    Hello All,
      Can someone advise on how am I able to add another row to my table upon the click of a button in Adobe Form ?
    Based on some sample PDFs that I downloaded from the net as reference, it seems that all I need to do is add the statment "_Car.addInstance(1)" in the script editor that will trigger upon a clicking of a button where Car is a subform that is of Type : Flow Content and Direction : Table Row set.
      Any suggestion/advise will be greatly appreciated.
    from
    Kwok Wei

    Hello Kwok Wei,
    in NW 2004s, this will be possible on the client using a special forms library object provided by Adobe.
    Be aware, though, that while you are able to add any number of additional lines on the PDF, the original Web Dynpro context is not aware of these actions. This means that your application needs to create the corresponding new nodes in the context before the data contained in these nodes can be submitted back to the application.
    Regards,
    Markus Meisl
    SAP NetWeaver Product Management

  • How to populate data in drop down box dynamically in adobe form?

    Dear Experts.
    I am new to adobe interactive form can anybody please tell me how to fill data in a drop down box dynamically? I am using webservices method.
    Thanks in advance.
    Chitta Ranjan Mahato
    Edited by: mahato123 on Aug 5, 2011 12:16 PM

    you can create a method to populate the context attribute that you are using to map to your dropdown box.
    DATA: node_info TYPE REF TO if_wd_context_node_info.
    DATA: it_table TYPE wdr_context_attr_value_list.
    ** select your dropdown data into it_table and pass it to your context attribute.
    ** here, mine is call PROJ_TYPE - the values should appear in your dropdown.
      node_info->set_attribute_value_set(
         name      = 'PROJ_TYPE'
         value_set = it_table ).

  • Text Field repeating at Page Break in Interactive Adobe form in Webdynpro Java

    I have requirement in which Text field containing 'Rich Text' data has a huge data coming at runtime. It is displaying correctly without any scrollbars on a single page .Now the problem is when data exceeds to next page ,text field repeats it with first line and also adds scrollbar to text field.
    I have set text field properties like Allow Page Break,Allow multiple lines ,Height Auto fit.
    Also The Text field is in flowed Subform ,Allow page breaks checked.
    Kindly provide solution in quick time..

    Yes I have checked all the subforms Flowed. Text field is working good in Preview Pdf Option of NWDS.
    But when I generate the pdf on server, when TextField flows to next page, on next page it repeats from first line.

  • Master page unnecessarily repeated in adobe forms.

    Hi ,
    The scenario i m trying to develop is to have data and an image field on the first page followed by only data on the next page.For this i have created two master pages and two body pages.The first master page has got an image field attached and 4 content areas.The second master page has got only 4 content areas.The pagination of the bodypages is done as described below :
    bodypage1--placed on master page 1,after : go to next content area ,if dataset must be paginated :goto next master page
    bodypage2--placed on master page 2,after : go to next content area
    The problem i am facing is result is displyed like :
    data on page like master page1 (required)
    empty page like masterpage1 (NOT REQD)
    rest data on pages like masterpage2(reqd)
    THIS EMPTY PAGE IS A PROBLEM.Can anyone tell where i m going wrong?
    Thanks,
    Ashwani Rohilla

    Hello,
    For this you need not create a master page, body page...complete design your whole layout in design view of default page...and dont change the settings of pagination tab... I think that should work.
    thanks,
    Rakesh.

  • Display a logo dynamically in adobe form

    Hi,
    I have to work on a similar requirement in coming 3 days.
    I have a suggesion why not use this method MIME_URL_FOR_BDS_GRAPHIC
    of the class CL_SSF_XSF_UTILITIES
    Thanks & Regards,
    Murthy

    Hi Murthy,
    thanks for your suggestion. I tried to use the method MIME_URL_FOR_BDS_GRAPHIC but it returns me a path not accessible directly append it to the portal URL.
    I used the code below for the ImageField "initialize" and "ready" events:
    this.value.image.href = xfa.resolveNode(this.value.image.href).value;
    this.access = "readOnly";
    but event this time...no image appers
    Regards,
    Mirco

  • Current page printing problem - while repeating pages : Adobe forms

    Hi Experts,
    I have a problem in printing current page number of an adobe form.
    My requirement is that , my form got 2 pages. On first page i am not printing page numbers and excluded from numbering.
    Numbering starts from second page. The second page needs to be repeated twice.
    In this case my page printing should look like :
    First page - no page number
    second page - 1 of 1
    Third page - 1of 1 (as it is a copy)
    IF second page extends to multiple pages (eg.. 2)
    First page - No Page no
    First instance of second page - 1of 2 , 2 of 2
    Second instance of second page - 1 of 2 , 2 of 2 . Presently it is printing like : 3 of 2 , 4 of 2. I need to initialize current page count. I could able to set the total page count 2 via variable from print program. But while printing the second instance, I am not able to initialize the current page count.
    I have seen the following thread which exactly talks about my problem but with out any solution.
    Re: Adobe Forms - Page Count
    Can any one help me in this regard.
    Thank You,
    Regards,
    Naresh.

    Hi,
    I am not sure how your page design looks like.
    Assumption:
    During runtime, ONLY 1 page for Page1, multiple pages for Page2 and Page3, same number of pages for Page2 and Page3.
    This is what i did:-
    I have 3 pages:
    Page1: With NO page number: ONLY 1 page
    Page2: With page number: Multiple page
    Drag the "Insert -> Custom -> Page n of m"
    - TextField: "CurrentPage",
    -- replace the original script: "this.rawValue = xfa.layout.page(this)" with "this.rawValue = xfa.layout.page(this) - 1"
    - TextField: "PageCount",
    -- replace the original script: "this.rawValue = xfa.layout.pageCount()" with "this.rawValue = ( xfa.layout.pageCount() - 1 ) / 2"
    Page3: With page number: Multiple page
    Drag the "Insert -> Custom -> Page n of m"
    - TextField: "CurrentPage",
    -- replace the original script: "this.rawValue = xfa.layout.page(this)" with "this.rawValue = xfa.layout.page(this) - 1 - ( xfa.layout.pageCount() - 1 ) / 2"
    - TextField: "PageCount",
    -- replace the original script: "this.rawValue = xfa.layout.pageCount()" with "this.rawValue = ( xfa.layout.pageCount() - 1 ) / 2"
    Good luck.

  • How to display page no for different master pages in one adobe form application

    Hi All,
    we have requirement where we need to  display page nos in different master pages in one single adobe form.
    For the First form the page nos should be displayed pgno of total pages and for 2nd form the page no shuld be displayed as pgno of total pg.
    so please help me with any script or suggestions for displaying the page no accordingly in different master pages. Your suggestions are greatly appreciated.
    Thanks
    Raja.

    Hi Lingaraj,
    We have 2 different Master pages and 2 Body pages. For the seccond Master page the page no are comming correct like 1 of 3 ,2 of 3 and 3 of 3 but for First master page the page no are comming 0 of 3  in all of the page its not displaying the current page no in 1st master page.
    Screen shots are attached for first master page and Hierarchy Node.Pls see the highlighted section in 2nd image.
    Pls see and suggest me accordingly. Hope this helps are let me know anything u require.

  • Populate Default Dynamic Filename In Adobe Form (On Click of Save in Menu) - SAP

    Hi,
    We have a scenario in which we want to populate the file name dynamically in Adobe form integrated in SAP Webdynpro.
    Scenario - 
    A adobe form has been intergrated in the SAP webydnpro application which opens the form in Web Browser (IE).
    There is a save button which is part of standard adobe form menu and on click of that save button (circled - 1 in image )  the name of the form ( i.e techincal name of adobe form created in SAP {ZTESTSS} ( circled - 2 in image ) appears.
    We want to change the default name to (employee_date_time ) on click of save.
    We have found a approch by using the folder level javascripts (http://forums.adobe.com/message/2266799#2266799%232266799).
    In case we use folder level scripts "where should we write the JavaScript code in the Adobe Form to trrigger the this script on click of Save Button (in the menu)?"
    Also is there any other apporch which does not require folder level javascript as its a security issue also we need to maintain in all the user systems.
    Please let me know the approch to address the issue.
    Thanks .
    Tausif

    Hi,
    you can't change the behavior of the save button in the browser nor in Reader/Acrobat.
    You can add a custom button within your form which calls a custom script from a folder level script using the browserForDoc method.
    The browseForDoc methos is the only one whcih can change the name in the saveAs dialog.
    Here's an example., you can run from Acrobat console.
    You need to combine it with the solution from the other thread to make it work with your form.
    http://forums.adobe.com/message/2266799#2266799%232266799
    var oRetn = app.browseForDoc({
        bSave: true,
        cFilenameInit: "MyForm.pdf",
        cFSInit: "",
    if (typeof oRetn !== "undefined") {
        this.saveAs({
            cFS: oRetn.cFS,
            cPath: oRetn.cPath,
            bPromptToOverwrite: false

  • How to change the page break in adobe forms

    Does anyone know how to change the page break on an adobe form?  I'm hoping it will be the same way you change the page view in excel.
    Can anyone help?
    Thank you in advance,
    Priscilla

    HI
          YOU CAN USE THE FOLLOWING SYSTEM FIELDS OF SMARTFORMS FOR THE MENTIONED PURPOSE
    <b>&SFSY-PAGE& </b>
         Inserts the number of the current print page into the text. You determine the  format of the page number (for example, Arabic, numeric) in the page node. 
    <b>&SFSY-FORMPAGES&</b> 
         Displays the total number of pages for the currently processed form. This  allows you to include texts such as'Page x of y' into your output
    <b>&SFSY-JOBPAGES& </b>
         Contains the total page number of all forms in the currently processed print  request.
    REGARDS
    ANOOP

  • Dynamic Image (.gif) from URL into adobe Form by SFP

    Hi all
    I post the comment of Shamila because I have the same problem
    I need to place an image in the Adobe form based on the url.
    I have written the following formcalc script in the image field form ready action
    ImageField1.value.image.href = "http://www.adobe.com/imageshome/pdfgift_home.gif"
    But when i view the form , the image field is empty, and when i click on the blank space of the image field, a popup appears to select the image............
    How can i show the image from url in the form..........
    Regards,

    Hello,
    have you checked these basics documents?
    When you need to send a picture into the offline form: another image question - using Regular ABAP not web dynpro and Display a logo dynamically in adobe form
    Where to start with scripting: http://www.adobe.com/devnet/livecycle/articles/lc_designer_scripting_basics/lc_designer_scripting_basics.pdf
    http://help.adobe.com/en_US/livecycle/es/FormCalc.pdf
    Also try: Re: Dynamic R/3 Image URL in Adoeb Form
    regards, Otto

  • Adobe Form's First Page printing perfectly on 132 column sheet but further pages prints with small font size

    Dear All,
    We are facing a strange behavior of adobe form.
    we made form for SAP CRM which is printing in 132 column(28cm * 33cm) sheet. what we are observing is, first page is printing perfectly on the pre printed Invoice sheet but if invoice has more items to be displayed then second  page prints with small font size or you can say second page seems to be zoomed out to smaller page size. In Preview Second page onwards also looks perfect. Now we are in a fix what to do to come out of this issue.
    efforts made:-
    Adobe Page Size Adjusted.
    Select paper Source by Page Size ticked in Adobe form properties
    But still result is non satisfactory. Please Help.
    Regards,
    Ashkar Rizvi

    See my answers below:
    a) The size of the pages of PDF which you are printing. LETTER
    b) Does all pages of the PDF are of same size? YES
    c) What is the page size set in the Printer and what is the actual size of the paper which you have put in the tray? LETTER
    d) Does this problem also happens on the virtual printer which you might have on your system (Try either Microsoft MPS Document writer or Adobe PDF Printer) No VIRTUAL PRINTERS
    Thank you for attempting to help me with this... we have tried everything and haven't been able to resolve the problem.
    Sherri

  • How to upload logo in adobe forms? is it possible to give logo dynamically?

    hi experts,
    1.i need to upload logo in adobe form.
    2. is it possible to get the logo dynamically in adobe forms.
       is it possible or not?
    thanks in advace

    Hi,
         In the form builder (tcode SFP), click on layout tab, just drag image icon from library into your layout and then specify it's localtion in your frontend. Also check the below thread,
        Uploading a logo
    Best Regards,
    Jayavardhan.

Maybe you are looking for