Triggering NEW-PAGE in the SAPSCRIPT

Hi All,
In the SAPSCRIPT for purchase order, in the last page i need to print terms and conditions. For this i have created third page(in MEDRCUK there are two pages) and i am trying to check the following condition.
IF &sapscript-formpages& = &page&
   NEW-PAGE THIRD
ENDIF.
But the condition never becoming true. Can somebody tell me how to achieve this.
Thanks in advance

> Hi
>
> Your control can't work, becuase the &PAGE& is the
> current page and &sapscript-formpages& is total
> number of page, but the system can know this data
> after loading completly your sapscript.
>
> If you want to know when you are at the last page,
> check the variable &NEXTPAGE& (for the number of next
> page), it'll be 0 if you are in the last page.
>
> IF &NEXTPAGE&  = '0'
> NEW-PAGE THIRD
> ENDIF.
>
> Max
>
>
> Message was edited by: max bianchi
Hi Max,
Thanx for your ur reply. I have tried with IF &NEXTPAGE& = '0' also, now also it is not working. In debug mode i checked the value of &NEXTPAGE&, only when the control leaves main window that time its value becoming ZERO. Actually in the last element of the main window the condition is written.
Regards
Rajavardhana Reddy

Similar Messages

  • Triggerring new page in the script

    Hi
    can anybody tell me how to trigger a new page in the script on condition.
    my problem is i want to print material & its discription based on the MRP controller using scripts.
    if the MRP controller changes then it has to trigger a new page in the script.
    page 1.
    MRP controller 102
    material1  material1-discription.
    material2 material2-discritpion.
    new page shoud trigger here
    page 2
    MRP Controller 103
    material1  material1-discription.
    material2 material2-discritpion.
    Thanks in advance

    Hi,
    First Call That text Element Were U Used New-page Coomand.
    SAPscript automatically inserts a page break when the main window of a page (MAIN) is full. You can use the NEW-PAGE command to force a page break in the text at any point you want one. The text following this command then appears on a new page. The page break is always performed (it is an unconditional page break).
    The NEW-PAGE command completes the current page. This means that all the windows that are still on the page are printed immediately. If you use the NEW-PAGE command without parameters, the page defined in the current form as the next page will be taken next. If, however, your form contains a number of different pages, then you can specify any one of these as the next page to be used.
    Syntax:
    /: NEW-PAGE page_name
    /: NEW-PAGE
    The current page will be completed and the text in the following lines will be written to the page specified in the form.
    /: NEW-PAGE S1
    As above, except that the page S1 will be taken as the next page.
    If, in a NEW-PAGE command, you specify a page not contained in the form, the specification is ignored.
    Take care that there are no blank lines immediately before a NEW-PAGE command. If an implicit page break occurs within the blank lines, an unexpected blank page may be printed.
    2.it can be set in two way
    1 using SE71 ur Script transaction
    u can create new page by clicking page tab in Se71 and goto edit->create Element.. that will create a new page..
    2 Using ur SE38 itself by setting a flag variable = X u can create a new page..
    if page = ' X '.
    new-page.
    endif.
    reward if helpful
    Shiva Kumar

  • Cannot open favourites using the Firefox tag that usually opens up the menu and a new page.. Now I get the dropdown menu but cannot open a new page, losing the homepage every time I explore, can you say WHY? all other versions worked fine!

    I cannot open a new page from the Firefox favorites menu, it worked before in other versions and this new 5.1 version, but stopped working a few days ago, uninstalled, downloaded a fresh program.. same problem exists. I usually leave my 'Home Page' as a stable page and just open 'new' pages for i.e. Google, Internet Banking etc. the '+' sign on my home page or other loaded pages does not operate, hate having to now constantly sign in to my hotmail home page if and when I open new pages, can you help?

    Websites remembering you and automatically log you in is stored in a cookie.
    * Create an allow cookie exception (Tools > Options > Privacy > Cookies: Exceptions) to keep such a cookie, especially for secure websites and if cookies expire when Firefox is closed.
    Make sure that you do not run Firefox in Private Browsing mode.
    * https://support.mozilla.com/kb/Private+Browsing
    * In [[Private Browsing]] mode all cookies are session cookies that expire if that session is ended, so websites won't remember you.
    * Do not use [[Clear Recent History]] to clear the "Cookies" and the "Site Preferences"
    Clearing "Site Preferences" clears all exceptions for cookies, images, pop-up windows, software installation, and passwords.
    * http://kb.mozillazine.org/Cookies

  • Why does a box that says "uninstal set" keep popping up when i go to a new page, refresh the page, or ever open up the browser ever i upgraded to the new firefox?

    I upgraded to the newer version of firefox, and ever since then every time i go to a new page, refresh the page, or open it the interned a box pops up and says "uninstal set" and won't let me continue until i click "ok" why is this happening, and how can i fix it?

    go to Tools, add-ons, then only disable java 6.0.22 ONLY, then you have to click on restart. That solved my problem.

  • Need to add a new page in the SAP Script as last page

    Hello,
    I need to add a new page in the SAP Script as last page.
    Currently I have three pages in the form(FIRST,NEXT,LAST). For this I created one more page END.
    FIRST page next page is NEXT
    NEXT page next page is NEXT
    LAST page next page is LAST
    END page next page is END.
    I used NEW-PAGE END in the main window but it is not working and also I trired with CONTROL_FORM this also not working.
    Thanks,
    Ravi.

    Hello,
    I need to add a new page in the SAP Script as last page.
    Currently I have three pages in the form(FIRST,NEXT,LAST). For this I created one more page END.
    FIRST page next page is NEXT
    NEXT page next page is NEXT
    LAST page next page is LAST
    END page next page is END.
    Create the text element in the main wondow of your form
    /E           ENDPAGE
    /:           NEW-PAGE END
    and call the element from your print program by using write_form, where you want the END page in your print.
      CALL FUNCTION 'WRITE_FORM'
        EXPORTING
          element = 'ENDPAGE'
        EXCEPTIONS
          element = 1
          window  = 2.
    Thanks,
    Ravi.

  • How do you make a link open on a new page (typically the target="_blank" command) in MUSE?

    how do you make a link open on a new page (typically the target="_blank" command) in MUSE?

    Newer version does not have the same interface.  I'm stuck trying to understand how to add a "blank" target to a hyperlink...  See how your screenshot has a dropdown associated with the "Hyperlink" object?  Mine doesn't...

  • How to insert a new page at the beginning of a chapter

    I tried to do that but not successful. Can we do that? What are the limitations of page/section adding on iBook Author?

    Hi narin1975,
    Welcome to Apple Support Communities.
    It sounds like you want to add a page in your iBooks Author project. Take a look at the iBooks Author Help webpage below, it will walk you through adding or deleting pages, chapters and sections.
    Add, reorder, or delete chapters, sections, and pages
    http://help.apple.com/ibooksauthor/mac/#blsa47d9392
    Add a new page
    In the Book pane (shown above), select the chapter or section you want to add pages to.
    Click Add Pages in the toolbar, and choose Pages > Option.
    Tip:  You can also add a new page by Control-clicking a page in the Book pane and choosing Insert Page from the shortcut menu. The new page uses the default layout for the chapter or section.
    I hope this helps.
    -Jason

  • When links are clicked, they do not fully display the NEW page until the mouse is moved.I know it is a current bug, and appears in no other browsers that I know of.

    It was pointed out that my links do not function correctly on Firefox on a Windows platform. When links are clicked, they do not fully display the NEW page until the mouse is moved! I have now observed it for myself on my fathers PC running Windows XP on Firefox.My PC is on Windows7
    It is the 5 version of Firefox, so I know it is a current bug, and appears in no other browsers that I know of.

    Start Firefox in <u>[[Safe Mode]]</u> to check if one of the extensions is causing the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > Appearance/Themes).
    * Don't make any changes on the Safe mode start window.
    * https://support.mozilla.com/kb/Safe+Mode
    If it does work in Safe-mode then disable all extensions and then try to find which is causing it by enabling one at a time until the problem reappears.
    * Use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.
    * Close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")
    In Firefox 4+ you can use one of these to start in <u>[[Safe mode]]</u>:
    * Help > Restart with Add-ons Disabled
    * Hold down the Shift key while double clicking the Firefox desktop shortcut (Windows)
    * https://support.mozilla.com/kb/Troubleshooting+extensions+and+themes

  • Can't add new page in the middle of document

    I am creating a manual and inserted page breaks at the end of each page as I created the document. Now I am trying to add a new page to the middle by inserting page breaks and even section breaks, but every time I try to add it in, it just goes to the bottom of the document and I am unable to move anything into the original 50 pages. Any tips here?
    When I look at the thumbnail view of the document it has all 50 pages in one yellow box instead of one page individually. A bit odd.

    The thumbnail browser shows one small page thumbnail for each page of your document. Each yellow bounding box indicates a section. So the thumbnail browser indicates your document has a single section with 50 pages in it.
    As you've typed your document it has naturally flowed from one page to the next. If you place a page break at the end of the page you are simply mandating what Pages has already voluntarily done. But if you insert a second page break you should get a new blank page. In other words, if you put your cursor at the bottom of page 6 and insert a page break you will move to the top of page 7 which has text because it is still page 7. Insert another page break and page 7 becomes page 8 and you'll have a blank page 7.
    Note: if you move your cursor into the middle of the document and insert a section break you'll see that the thumbnail browser shows two sections; one ending on the page above your cursor and one starting on the page your cursor is in. This is useful to understand.
    Second Note: if you use the Insert>Sections option it always inserts a new section at the bottom of the section your cursor occupies. Since your document currently has one section, that's why you wind up with the inserted page at the end of your document.

  • Can i Open a new page behind the current one in the browser?

    Using Safari, if I press a link to 'open in new page' is there a way to have the new page open behind the current one? I can choose it on my laptop browser(windows). It's really annoying when I choose 'open in new page' and the current one is whisked away, then I have to minimise it and go back to the original.

    There are other browsers available that have the tabs feature which is so much handier when navigating from page to page like you want to do.
    Look at iCab (my favorite), Mercury and Atomic. All three have many more features than Safari has.

  • Can you get a free download of the new Pages through the appstore if you already have an earlier version of iworks from a disk?

    I have loaded mountain lion on my iMac and have an old version of iWorks on my machine.  It appears that all my Pages documents won't open unless I get the new version of Pages off the App store.  Does anyone know if that is a free download if you already have purchased iWorks previously on disk?  Thanks.

    No. The iWork (no 's') apps are a separate purchase. You should not have to buy any of the '09 apps again to work in Mountain Lion, you just need to update them.
    iWork '09 installed from the retail disk or from the downloaded trial must be updated through Software Update. In Mountain Lion Software Update has been "rolled into" the Mac App Store. Choose Software Update from the Apple menu just like you always have & the Mac App Store will launch. Depending on what you have that needs updating you may see two sections in the MAS window.
    But, as always, if you're not running the latest versions of the iWork apps installed from a retail box or the downloaded trial & Software Update says your software is up to date, make sure the applications are where the installer initially put them. The updaters are very picky. If the location is not where the updater is programmed to look or if the folder doesn't have the name the updater looks for, it will not work. The applications cannot be renamed or moved. If you installed from the downloaded trial or the retail box, they must be in the iWork '09 folder in Applications. That iWork folder must be named iWork '09. If it doesn't have the '09 Software Update won't find them & the updaters won't work.
    Alternatively, you can download the standalone updater here.

  • How do i put apps on a new page, not the game center

    i tryed to install new apps to my sisters ipod touch, they keep going in the game center and not on a new page.  She dosent have wifi to use with the game center so how can i get them out of there.  ive tryed to drag and place them from the app screen on itunes and the appeare but are not on the ipod

    Sign in to the iPhone or connect the phone to the computer and sign into the store using the original ID and download the apps to the phone?

  • New page when the fields changed

    Hi all,
    I wanna display my report on  next when my BEZEI_T gets changed. I used at-new command also .. but its not working.. and also i want that new bezei_t get stored in some variable and change the header of the report. Please guide me. My code is:
    LOOP AT IT_FINAL.
    AT NEW BEZEI_T.
          new-page.
        endat.
      WRITE: / sy-uline,
               IT_FINAL-name_full1,
               50  IT_FINAL-STRAS,
               100  IT_FINAL-NAME_FULL,
               160 IT_FINAL-STCD2,
               / IT_FINAL-BEZEI_T,     
                50 IT_FINAL-CUS_ADD,
               100    IT_FINAL-TELFX,
    ENDLOOP.
    Regards
    Puneet

    Try this...
    LOOP AT IT_FINAL.
    AT NEW BEZEI_T.
    new-page.
    WRITE: / sy-uline,
    IT_FINAL-name_full1,
    50 IT_FINAL-STRAS,
    100 IT_FINAL-NAME_FULL,
    160 IT_FINAL-STCD2,
    / IT_FINAL-BEZEI_T,
    50 IT_FINAL-CUS_ADD,
    100 IT_FINAL-TELFX,
    endat.
    ENDLOOP.
    Cheers,
    Tatvagna.

  • Steps for adding a new field in the sapscript

    pls give me the step by step procedure to insert a new field in the sap script.
    like wat i need to to do in the form layout/line editor
    and wat n how i need to change in the print program like subroutine, etc..
    where should i use the itcsy structure?

    Hi,
    This will give you a step to step procedure for SAPScript.
    <a href="http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVSCRPROG/BCSRVSCRPROG.pdf">SAPScript</a>
    regards,
    Amit
    Reward all helpful replies.

  • How do I post to a new page when the 1st page is full?

    How do you create a bul. board where the posts go on a 2nd
    page when the first page is filled ...and 3rd page when 2nd is
    full, etc ... Maybe I can stick a wordcount in a while loop before
    the CFOutPUT Tag? Is there such a variable that holds a word count
    or better still, a line count?
    thnx a billion, please, please help!

    Check out this code-Use a cfc which will be the same for you
    and then change my query for yours in the .cfm HTHs:
    functions.cfc:
    <cfcomponent output="yes">
    <!--- Next x record function --->
    <cffunction name="nextXpage" access="public"
    returntype="struct" hint="Next x page function" output="No">
    <cfargument name="recordcount" required="Yes" default="0"
    type="numeric" hint="The total numbers of records / values">
    <cfargument name="page" required="Yes" type="numeric"
    default="0" hint="The page number that you are currently on. (for
    example URL.page)">
    <cfargument name="maxrows" required="No" type="numeric"
    default="10" hint="The maximum records / values to be displayed per
    page">
    <!--- Define the return structure --->
    <cfset var nextXpage = structNew()>
    <!--- Calculate how much page are available according to
    the maxrows displayed --->
    <cfset nextXpage.pagecount =
    CEILING(arguments.recordcount / arguments.maxrows)>
    <!--- Set the maximum rows to be displayed --->
    <cfset nextXpage.maxrows = arguments.maxrows>
    <!--- Set the currentpage --->
    <cfset nextXpage.currentpage = arguments.page>
    <!--- Set the currentpage --->
    <cfset nextXpage.recordcount = arguments.recordcount>
    <!--- Set the startrow value --->
    <cfif arguments.page eq 1>
    <cfset nextXpage.startrow = 1>
    <cfelse>
    <cfset nextXpage.startrow = (arguments.page *
    arguments.maxrows) - (arguments.maxrows -1)>
    </cfif>
    <!--- Define the previous and next values. --->
    <!--- Next values --->
    <cfif arguments.page neq nextXpage.pagecount>
    <cfset nextXpage.next = true>
    <cfset nextXpage.nextpage = arguments.page + 1>
    <cfelse>
    <cfset nextXpage.next = false>
    <cfset nextXpage.nextpage = 1>
    </cfif>
    <!--- Previous values --->
    <cfif arguments.page eq 1>
    <cfset nextXpage.previous = false>
    <cfset nextXpage.previouspage = 1>
    <cfelse>
    <cfset nextXpage.previous = true>
    <cfset nextXpage.previouspage = arguments.page - 1>
    </cfif>
    <!--- Return the structure --->
    <cfreturn nextXpage>
    </cffunction>
    </cfcomponent>
    Then on your output page where you have the info:
    .cfm page:
    <cfquery name="qrysales"
    datasource="davanzo_villa.admindb" >
    SELECT DISTINCT
    clientinfo.Id, clientinfo.RemoteAddress, clientinfo.visit,
    clientinfo.country
    FROM clientinfo
    order by clientinfo.Id
    </cfquery>
    <!--- display hit counter --->
    <cfquery name="GetHits">
    SELECT * FROM hit_counter
    </cfquery>
    <cfparam name="URL.page" default="1">
    <!--- Determine the navigation parameters --->
    <cfset functions =
    createobject("component","functions")>
    <cfset nav =
    functions.nextXpage(qrysales.recordcount,URL.page,15)>
    <table width="792">
    <h4>Total Hits: <CFOUTPUT
    query="GetHits">#hit_count#</cfoutput></h4>
    <h4>Total Unique Visitors:
    <cfoutput>#qrySales.RecordCount#</cfoutput></h4>
    </table>
    <table width="792">
    <tr><td>
    <cfoutput>Unique Visitors: #nav.recordcount# (page
    #nav.currentpage# of #nav.pagecount#)
    <cfif nav.previous>
    <a
    href="hitcount.cfm?page=#nav.previouspage#">Previous</a>
    <cfelse>
    Previous
    </cfif>
    <cfif nav.next>
    <a
    href="hitcount.cfm?page=#nav.nextpage#">Next</a>
    <cfelse>
    Next
    </cfif>
    <ul>
    <cfloop From = "1" To = "#nav.pagecount#" index =
    "pagenumber">
    <cfoutput>
    <a
    href="hitcount.cfm?page=#pagenumber#">#pagenumber#</a></cfoutput>
    </cfloop>
    </ul>
    </cfoutput>
    </td></tr>
    </table>
    <table width="792">
    <tr>
    <td>Date</td>
    <td>Visitor Number</td>
    <td>Visitor`s IP Address</td>
    <td>Visitor`s Country</td>
    <td>Path Taken</td>
    </tr>
    <cfoutput query="qrysales" startrow="#nav.startrow#"
    maxrows="#nav.maxrows#">
    <tr>
    <td>#qrySales.visit#</td>
    <td>#qrySales.id#</td>
    <td>#qrySales.RemoteAddress#</td>
    <td><cfif qrysales.country neq ""><a
    href="country.cfm?Remote_Addr=#qrysales.RemoteAddress#">#qrySales.country#</a><cfelse><a
    href="country.cfm?Remote_Addr=#qrysales.RemoteAddress#">Find
    country</a></cfif></td>
    <td><a href="hitpathdetails.cfm?id=#id#">See path
    taken</a></td>
    </tr>
    </cfoutput>
    </table>

Maybe you are looking for

  • Itunes 11.1.4 mobile driver

    Last week itunes 11.1.4 popped up I installed then when I went to service one of my apple devices found the following the new mobile device driver would install for iphone ipod touch ipad then trust this computer would show on my devices the window t

  • Simple color control panel.

    My largest beef with Lightroom is that for the most part, the HSL sliders are good for creative color but difficult and slow for color corrections. And the white balance controls are terrible for color corrections when used to an RGB system as used i

  • IPad with Retina Display (4th Generation) Factory Unlock

    I want to buy iPad with Retina Display from apple website but I can choose only 3 carriers provider. I've read that there are actually not lock and I can use any carrier provider I wish. Is that true?. So instance I will buy iPad from apple website a

  • Time Capsule and PC Connectivity when Airport Utility is not available

    I want to connect a PC to a time capsule via Ethernet to use the LAN Connection. The PC does not have Airport Utility installed (corporate restrictions) and does not recognise the connection when I plug in the network cable. How can I fix this proble

  • Decimals used on FX rate

    Hi, I have a consolidation system which does the FX translation. I enter the rates against the EUR and the system then triangulates the rate when I run a conversion to USD. For this triangulation BPC works with the maximum number of decimals allowed