Sap script current page name

HI experts,
can any body tell me how can i get the current page name in sap script.
In case of smartform we can get it by using sfsy-pagename. is there any way like this.
rgds,
bharat.

Hi Bharath,
Follow this procedure...
Got to
Insert (MENU)-> Symbols->System symbols-> TTXSY SAPscript system symbol
                                          (select it )
                                          Click Choose button
                            - from here select PAGE.
Insert (MENU)-> Symbols->System symbols-> SAPSCRIPT      SAPscript system fields
                                          (select it )
                                          Click Choose button
                            - from here select -> FORMPAGES  Total number of pages
In editor it appears as &PAGE& &SAPSCRIPT-FORMPAGES&
just type Of between them as below
&PAGE& Of &SAPSCRIPT-FORMPAGES&
So that it will be in readable format for user.
Regards,
Basheer.

Similar Messages

  • Satndard SAP script or form name to generate FI invoice

    Plz let me know if u know the standard SAP script or form name to generate the FI invoice.
    Regards
    Nivetha.

    Hi,
    I guess the terminology's causing some problems.  Here's what I think you need to do;
    In transaction V/30 select the Output Type then double-click on the folder 'Processing Routines'.  The columns are as follows;
    Medium - Print, email etc
    Program - Name of the print program
    FORM Routine - name of the subroutine in the print program that will be called
    Form - Name of the SAPscript (if used)
    PDF/Smartform Form - Name of the Smartform, or pdf form (if used)
    Type - If a Smartform or pdf form is specified, select from this drop-down which type it is.
    If you're getting an error when you enter your parameters, it would be useful if you told us what the error was.
    Regards,
    Nick

  • Display current page name using API ?

    I want to display the current page name using a PL/SQL API. I can get it using smart text - current page item, but I need to get it programmatically using a procedure. Which one? What variable? If I need to pass values in, where do I get them?
    Thanks,
    John

    You can use wwpro_api_parameters.get_value('_pageid','a') in a pl/sql item or UI template to get the value of the current page id. You can then use the page id to look up page attributes in the WWSBR_ALL_FOLDERS view. In a portlet, you have to use the reference_path instead of the 'a' as the second parameter.
    Please note that is is an undocumented use of this API and is not guaranteed to work in future releases. However, it does work in 9.0.2 and 9.0.2.6. WWSBR_ALL_FOLDERS is not officially supported until the 9.0.2.6 version.
    Regards,
    Jerry
    PortalPM

  • How to find out current PAGE NAME (not Page No) in SAPSCRiPT

    Hi,
    Is there anyway i can find the current page name in sapscripts which i can check in IF condition and accordingly perform some task. I searched and found out ITCTG-TDPAGE structure but its giving me error when i try to print in text element editor.
    Regards
    Amber

    Hi Amber,
    the otf[]-Table is located in a function group...
    Sry, forgot to add this.. that's the thing without a system available
    To solve your problem, I would work with the otf-data. I just can give you suggestion because the solution might be a bit bigger.
    Set yourself a unique string into the line you want to draw a box (perhaps @BOX1). Afterwards you can replace this variable with things you want to do. There is a lot possible with having the otf-data itself.
    Important is, that you do this before calling CLOSE_FORM
    Regards
    Florian
    BTW: OP are the first two unique chars in the line
    Here is a example-coding
    FIELD-SYMBOLS: <gt_otf> TYPE ssftotf,
       <ls_otf> TYPE itcoo.
    ASSIGN ('(SAPLSTXC)OTF[]') TO <gt_otf>.
       IF sy-subrc = 0 AND <gt_otf> IS ASSIGNED.
    LOOP AT <gt_otf> ASSIGNING <ls_otf>
         WHERE tdprintcom = 'ST'
         AND tdprintpar+7 = '@UL1'.
    ENDLOOP.
       ENDIF.

  • To add Cover page in SAP Script if pages are more than 10.

    Hello Experts,
    I want to print a Cover page first if and only if number of pages exceeds 10 in SAP Script.
    Cover Page should be the first page and then the remaiing pages.

    It's not possible to find the no of pages the script will generate, until it's printed. Again, you need the cover letter as the first page.
    There could be a solution to your requirement. Call the script and get OTF format without printing it to spool. You will get to know the no of pages in the main script . If it's more than 10, call the secondary script to get the OTF data of cover letter. Merge the OTF of main script to OTF of cover letter and print the OTF data to spool using FM PRINT_OTF.
    Check this link for similar code. In your case, the spool of the two sapscripts needs to be merged.
    Re: Smartform to Spool

  • Regarding SAP SCRIPTS - NEXT PAGE FUNCTIONALITY

    Hi all,
    Can anybody tell me how to get NEXT PAGE FUNCTIONALITY   in SAP SCRIPTS. Means if Data in 1st page does not fit it should go to next page and print.
    I had declared 2 PAGES already in my LAYOUT SET.
    How can i achieve above functionality.
    Thanks in advance.
    Thanks & Regards,
    Rayeez.

    Hi Rich heilman,
    I had declared first page as PAGE1 & its Next Page attribute as PAGE2 which is also declared already.
    But still it is not showing second page when there is over flow of data.
    does we need to write following code any where in layout.
    IF &PAGE& EQ = 1
    NEXT-PAGE
    ENDIF
    please solve my issue.
    Thanks & Regards,
    Rayeez.

  • SAP script extra page at end....

    Hi Experts,
    I am using SAP Script Form, After executing a script in output one extra page is comming. How to remove that extra page ?
    Rahul

    Hi,
       Check your main Window, may be there is blank line at the last of the main window, so check that abd remove that,so you won't get the blank page.
    If U WANT TO GET THE LAST PAGE THEN
    You have to check the system variable &NEXTPAGE&, if it's 0 it means you're in the last page.
    From SAP Help:
    This symbol is used to print the number of the following page. The output format is the same as with &PAGE& .
    Note that on the last page of the output, in each window that is not of type MAIN, &NEXTPAGE& has the value 0.
    /: IF &NEXTPAGE& = '0'
    Last page
    /: ENDIF
    Reward points
    Regards

  • How To Display Current Page Name in Text Box Titles?

    <BR>I have a report which uses a page dimension. When I print out the report, it does display the page dimension member in plain text, near the beginning of the report. But I would like to incorporate the current page value in the formatted report title, a text box.<BR><BR>The "MemberAlias" command, for example, looks like this:<BR><BR>(( MemberAlias("GridName", Row/Col/Page, "DimName") ) )<BR><BR>(substituting the less-than, greater-than symbols for parentheisis just for this web forum)<BR><BR>If I put a number in as the second element in the function, that hard-codes the report to print the page 1 value on each page of the printout. Unfortunately, Reports doesn't allow the "current" value in a text box. Is there a way to do this?

    hi,
    is there any generic fix for this. if we want to display then we need to change the each page CO . is it a possible solution. or any generic solution. Please provide
    Thanks
    Smarak

  • Sap script form pages

    Hi,
    My client wants some text in the last page above footer.
    I have given
    if &page& = &sapscript-formpages&.
    include (some text)
    endif
    but in debug when page is 1
    formpages is 0.
    Any inputs in this regard would be appreciated.
    Thanks in advance.
    Syed

    Hi Syed ,
    The last page in script is shone as 0.
    so we need to che check with 0.
    try this code.
    if &page& = 0.
    include (some text)
    endif.
    OR
    if &sapscript-formpages& = 0.
    include (some text)
    endif.
    OR
    if &NEXTPAGE& = 0.
    include (some text)
    endif.
    either of this three will works.
    Regards,
    Ramesh.

  • SAP Script Single Page

    Dear all,
      There are two pages defined in standard SAPScript invoice form FIRST and NEXT.  Now i want to maintain only one page in the SAPScript. What is the correct procedure to achieve this?? Does this change require update in the print program??
    Regards,
    Kit

    Hi Manju,
    I create a new window (no main) but does not run, please can you tell me what should I do to make it work.
    Best regards.
    Robert.

  • Getting to know current page name

    How to realize the subject?

    Well, f.i. page location is http://127.0.0.1/test/index.jsp
    and i should to get `index.jsp`, if location is
    http://127.0.0.1/test/blabla.jsp
    than `blabla.jsp`.

  • New page creation in sap scripts

    Hai
    some one can give me the path for creation of  new page in sap script(forms).
    pl giove me the complete path
    thank u in advance

    hi
    Goto SAPSCRIPT transaction code se71.
    open your sap script.
    goto pages button
    right click
    create element
    a new page element gets created
    fill in required details of this new page like page name next page
    next page is the page that comes after the current page
    if you have no next page - give the current page name in next page.
    you can further create windows in this page and continue
    Regards,
    Richa

  • Creation of New Page in SAP Script

    Hi Experts,
    Please advice when will a new page trigger in SAP Script :
    As per my requirement I need to create a new page for an existing layout and make changes to the second page alone...
    but this page should be triggered only for a specific condition. Is it possible to trigger second page when it satisfies certain conditon?
    I have searched SDN regarding the same but most of them have recommended to use NEW-PAGE...but as per my understanding NEW-PAGE is used when certain data needs to be printed on the next page ( not on the new page ).
    Thanks
    Karthik.R

    Ok friend,
    Try using the conditions in your driver program using 'CONTROL_FORM' function module. or using some other condition in it.
    You can also give conditions in text editors and you can trigger the pages.
    i think these links will help you in solving your solution just check these Link: [new page based on condition in sap script|new page based on condition in sap script; this is just an hint from this you can develop the idea.
    Link: [Breaks in Smartforms|LAST PAGE FOR SAP SCRIPT;.
    Also there are other few related links in SDN which will help you.
    I think this must solve your issue if you still face any queries please revert back to me i will help you.
    Thanks,
    Sri Hari

  • How to get Current Page(region)  Name/ID   in OA 11i

    We need to get the name or id of the current page, and based on the pagename, we retrieve configuration to launch specific web service.
    pageContext.getPageLayoutBean().getPageFunctionName() is no sufficient. Since one page function sometimes contain multiple pages (eg, each individual page maps to one train node, all the train nods maps to one page function).
    are there OA apis that I can use to get the Current Page name in controller?
    I tried pageContext.getParameter("CurrrentPage") , it works great for iExpense application. However, in iRrecuiment, the parameter "CurrentPage" was not set at all.
    Please advise.

    First let me explain what I want to achieve:
    I am writing one region (choice list displays the webservices based on the container region) along with the controller, and that region will be embed inside any OA application pages via OA personalization. On the runtime, I need to detect the current page (container region) name. Then, based on the configuration stored in my table, I need to query out the web services endpoint to call.
    Now let me answer your question:
    For example, OIEMAINPAGE.xml (OIEMainPageContainer) contains OIEReview, OIEDetail, OIEGeneral, etc, each inner region will be rendered as a page when you click the train node or link of other page. (from end user perspective)
    If I call pageContext.getPageLayoutBean().getPageFunctionName() on those inner regions, it will return OIEMAINPAGE, so I can not figure out which region are rendered (displayed) on runtime. (My region are embed inside OIEMAINPAGE pagelayout region )
    If I call pageContext.getParameter("CurrrentPage"), it will return (OIERview, OIEDetail etc), which are exactly what I want.
    However, I have to make sure my code works for other OA application, and I already noticed that some application does not set parameter CurrentPage, instead they may set parameter Page. So, I want to know if there is API provided by OA or fnd team to return current container region (page), very similar to Form Block name.
    In form, One Form function could have multiple Blocks, and they are not displayed at same time.
    In OA, one function could have multiple inner container region, and they are not displayed at same time.
    In form, One Form function could have mutlple Blocks, and they are not displayed at same time.
    In OA, one funciton could have mulple container region, and they are not displayed at same time.

  • How to get a Page name?

    Hello,
    I have a dynamic page component portlet, which display different images depending upon page name.
    Is there any APIs to get the current page name in pl/sql.
    or is there any way to get the page name ?
    Thanks
    Sha

    I can't help you with the Javascript option - don't know if this is possible.
    A simple PL/SQL item type that demonstrates how to do this:
    declare
    page_id varchar2(100);
    begin
    page_id := WWPRO_API_PARAMETERS.GET_VALUE('_pageid','a');
    htp.p('The page id is ' || page_id);
    exception
    when others then null;
    end;
    A custom item type procedure is even simpler - you can pass the page group id and page id directly to the procedure, so you don't need to call WWPRO_API_PARAMETERS.GET_VALUE to pull the pageid off the URL.
    There is a very good example of using custom item type procedures in this submission on the Knowledge Exchange. You must register for Portal Developer Services to access the Knowledge Exchange.
    If you are not familiar with PL/SQL item types and/or custom item procedures, please consult the documentation.
    Regards,
    Jerry
    PortalPM

Maybe you are looking for