Dispaly standard text in SAP SCRIPT which content saved using SAVE_TEXT FM

I want to display one standard text content in SAP SCRIPT and want to store content of it during run time.
For that, first I have created one standard text using SO10.Named the standard text as Z_TEST_WRITE. Initially it was empty.
In my SAP SCRIPT, I try to display the content of the standard text using below given SAP SCRIPT code and report program. Although I am able to store text in Standard text
Z_TEST_WRITE but in first display of the SCRIPT it is not displaying against the include command of SAP SCRIPT. But when I see the content of Z_TEST_WRITE through SO10 transaction, I can see the content with new text which was previously empty.
Now if I do the same transaction newly (suppose second time), then text stored in standard text Z_TEST_WRITE is displaid against includes command of SAP SCRIPT.
My print program is a SAP STANDARD which one can be changed.
/:   DEFINE &NAME& = ''                                      
/:   PERFORM TEST IN PROGRAM Z_SAVE_TEXT
/:   CHANGING &NAME&                                         
/:   ENDPERFORM                                              
  <B>&NAME&</>                                            
/:   INCLUDE Z_TEST_WRITE OBJECT TEXT ID ST
REPORT  Z_SAVE_TEXT.
FORM TEST TABLES IN_PAR STRUCTURE ITCSY
OUT_PAR STRUCTURE ITCSY.
  DATA IT_HEADER LIKE TLINE OCCURS 0 WITH HEADER LINE.
  DATA: LS_HEADER LIKE THEAD,
        LT_LINES  TYPE STANDARD TABLE OF TLINE WITH HEADER LINE.
  OUT_PAR-NAME  = 'NAME'.
  OUT_PAR-VALUE =  'Sample text for Test'.
  APPEND OUT_PAR.
*-Populate Header Text details
  LS_HEADER-TDOBJECT  = 'TEXT'.
  LS_HEADER-TDNAME    = 'Z_TEST_WRITE'.
  LS_HEADER-TDID      = 'ST'.
  LS_HEADER-TDSPRAS   = SY-LANGU.
*-Populate details of Text
  CONCATENATE 'Shipment No   :' 'RM Ship No' INTO LT_LINES-TDLINE
  SEPARATED BY SPACE.
  LT_LINES-TDFORMAT = '*'.
  APPEND LT_LINES.
  CONCATENATE 'Bill of Lading:' '1234567' INTO LT_LINES-TDLINE
  SEPARATED BY SPACE.
  APPEND LT_LINES.
*-Save Text
  CALL FUNCTION 'SAVE_TEXT'
    EXPORTING
      CLIENT          = SY-MANDT
      HEADER          = LS_HEADER
      SAVEMODE_DIRECT = 'V'
    TABLES
      LINES           = LT_LINES
    EXCEPTIONS
      OTHERS          = 1.
  IF SY-SUBRC NE 0.
    EXIT.
  ENDIF.
COMMIT WORK and WAIT.
ENDFORM.                    "TEST

Hi,
  If the text is getting displayed the second time, then this should be due to delay in saving the text.
After your COMMIT WORK AND WAIT in your report program, just put a WAIT FOR 2 SECS and check again.
Regards,
Suganya

Similar Messages

  • Problem in using standard text in SAP Script

    Hi All,
    I have to replace English text hardcoded in a script with standard texts (SO10) in Spanish. When I am including the standard text in script, it is displayed in different font and bigger size. I want to reduce the size and change the font of standard text. Is there any way to do that?
    Thanks in advance
    Radhika
    <MOVED BY MODERATOR TO THE CORRECT FORUM>
    Edited by: Alvaro Tejada Galindo on Jan 4, 2010 2:37 PM

    Please check the links below , which might hel you..
    Re: Setting font to standard text in sap script
    How to change stranded text font in script
    Regards
    Satish Boguda

  • Standard text in SAP Script

    Hi All,
      I am Creating Standard text in SAP Script. I want to Transport it to Quality and Production servers.But while saving standard text it is not asking transport request no.weather we need to create the text seperately in quality and in production or we can attach it in to transport request. Please suggest me.
    Thanks and Regards
    Partha.

    Hi partha,
    1. We can use the standard program
       RSTXTRAN
    2. It is meant specially for this purpose only.
    (we can attach standard text to a transport request)
    regards,
    amit m.

  • How to use Standard text in SAP SCRIPTS

    Hi all,
    Please tell me how can we use the standard text what we have created in SO10 with sap scripts.

    Hi Gaurav
    You can create standard texts using the transaction SO10. Then to insert these standard texts in the SAPScript choose the menu, Insert->Text->Standard and choose the standard text that you want to choose.
    Alternatively, you can display standard texts in your SAP Scripts using the command:
    INCLUDE ZSTEXT OBJECT TEXT ID ST LANGUAGE EN
    where ZSTEXT refers to the Standard Text name.
    Reward pts if found usefull
    Regards
    Sathish:)

  • Problem in long text in SAP script editor

    Hi ,
    i am maintaining long text in SAP script editor , when i am trying to change the long text in SAP script that changes are not reflected in print preview ,for example when i am giving tabs in the script then in print preview of the PO these tabs are displayed as , , ( comma) , and underlines are not appearing in print preview.please help me on this.
    Thanks and regards.
    Rajeshwar.

    hi
    you have to install the correct printer which supports the displaying the drawings and objects/

  • Problem passing texts into sap-script

    Dear Experts,
    I have a requirement, where I have to pass some text-lines from my selection-screen of the driver-program to the sap-script,i.e. whatever I write in those text fields that should be displayed(printed) on the specified place of my script. Another specification is  that,
    those lines will get printed only if the checkbox on my selection-screen is checked.
    What should be the procedure,please help me.

    The text lines on the selection screen will be in a variable. Pass the variable to the SAPScript. I don't see the problem.
    Rob

  • Formatted Text Edit & SAP Script Text

    I'm working through a business requirement to input some long text, and then update an existing SAP script text object (attached to a sales order).
    I'm using a formatted text editor to allow the users to enter the text - however I can't find a utlity that allows me to convert this data into a format that can be saved into a sap script text.
    Thanks,
    Heather

    Hi Heather,
    Please check this...
    Re: From Web Dypro Text area to SAP Script  text object(Tline table)
    http:///Tutorials/Smartforms/PassingTableData/Script1.htm ... add saptecnical.com before tutorials.
    Cheers,
    Kris.

  • Standard text in SAP smartform

    Hi Friends,
    This is regarding Smartform standard text.
    I supposed to populate some standard text based on the some condition. i mean.. is there any possibility topopulate standard text dynamically.
    pls help me.
    Thanks in advance
    Raghu

    Hi,
    When I passed standard text statically, it is working.
    But the same parameters when I pass through include command it is not working.
    INCLUDE 'ZNOTE' OBJECT TEXT ID ST LANGUAGE EN
    Pls help me. this is very urgent.
    Regards

  • Bi Content in 7.0 - Did SAP Convert all content to use new ETL process?

    Hello.
    I am working with BI 7.0 for the first time.  I have 8 years of BW 3.x experience.  We are starting a new BI project and we are in the process of activating Business Content.  We have BI_CONT level 7 (the latest as of today I believe).  I appears that SAP has not converted over its Business Content to use the new ETL process (Transformations, DTP's, etc).  For example, I am looking at basic areas such as AP, AR, SD, MM, GL, etc and the BI content is still using the 3.x ETL (transfer rules, update rules). Is something not installed right on my system or has SAP not converted it's content to the new ETL yet?
    Thanks in advance for your help.

    Jose,
    Some new content is released using the new DTP.  Most content remains in its delivered 3.x format.  If you want to use DTPs for this content you have to manually create the DTPs after installing the 3.x objects.  If you right-click on an InfoCube, you will see some new options in the context menu, including "Create Transformation...," and "Create Data Transfer Process...."  Context menu for DataSouce now contains a "Migrate" option that will allow you to migrate to the new DTP from 3.x.  Also, other objects such as Transfer Rules and Update Rules contain context menu options for "Create Transformation."
    Hope this helps.

  • SAP CM25 which profile to use and why and some general questions

    Hi there,
    I have a few general questions, if you may share your thoughts on this.
    In a manufacturing environment, is CM25 more used to finite schedule the work centers or labor or both ?
    Is it a good idea to even finite schedule the planned orders or just production orders ? We want to create production orders 1 week ahead of the production schedule and planned orders gets created 3-4 weeks earlier than production order gets created.
    The graphical tool seems to be slow sometimes when dispatching and doing some actions on the screen, has any one have any say on this. Should we need to have better computers on the floor for this to work ?
    I have been trying my solutions using CM25 and not CM21 or CM27 using the profile SAPSFCG005, is there any other profile that I need to consider and other transactions to consider like CM21 or CM27 for certain purposes?
    Thank you

    Hello
    In a manufacturing environment, is CM25 more used to finite schedule the work centers or labor or both ?
    It can be used for both depend upon bottle neck resource whether machine or labour.
    Is it a good idea to even finite schedule the planned orders or just production orders ? We want to create production orders 1 week ahead of the production schedule and planned orders gets created 3-4 weeks earlier than production order gets created.
    Better it should be finite planning for planned order also you can use MRP with lead time scheduling.
    The graphical tool seems to be slow sometimes when dispatching and doing some actions on the screen, has any one have any say on this. Should we need to have better computers on the floor for this to work ?
    It depends upon the data load and selection,
    Restrict the number of objects to be displayed, for example, select only a small number of work-centers/orders.
    Customize the time profile (transaction OPD2) such that the database read period, the planning period and the evaluation period are as small as possible. As a result, fewer objects are read and displayed.
    Refer KBA  2038780 - Tips for performance improvement on Capacity Leveling
    If you want to process more orders, check whether a batch planning (planning in the background on transaction CM40) is possible.
    I have been trying my solutions using CM25 and not CM21 or CM27 using the profile SAPSFCG005, is there any other profile that I need to consider and other transactions to consider like CM21 or CM27 for certain purposes?
    It depends upon your requirements which transaction to use and which profile. You can customize your own profile also.
    Best Regards,
    R.Brahmankar

  • Format for hiding the text in sap script

    Hello gurus,
    I waanted to know if there is any tag column to hide a text in corresponding line. My detail requirement is that I need to add GUID as a indicator at the beginning of the formatting text but that should not be visible to the user. currently you can protect the text i.e not allowing the user to make changes to the text by using tag '>X'. Like that is there any tag for hiding. I am not able to get it.
    thanks and regards.

    Hi,
    Try it using
    Hidden - Standard Attribute for Character Formats
    The character string is not printed. The text is only visible in the text editor.
    Also, check
    http://help.sap.com/saphelp_46c/helpdata/en/d2/cb3d07455611d189710000e8322d00/frameset.htm
    Regards,
    Edited by: Neenu Jose on Nov 5, 2008 5:04 AM
    Edited by: Neenu Jose on Nov 5, 2008 5:06 AM

  • Printing  page number and continu text in sap script

    Hi
      I have created sapscript to print PO and using standard print program with three pages.
    My thrid page called with NEWPAGE <> from Main window of first or sencond page wokign fine but the page number is coming like page 1 of 2, 2 of 2 and 3 of 2
    another issue: I want to print continue text if sapscript has more than one page, Not included last above newpage <page>
    Please give me some idea how to go about above two
    Regrads,
    challa

    Hello,
    TO print the page number do like this
    <b>&Pages& of &SAPSCIPTS-FORMPAGES&</b>
    To print continues pages. Put the text in the <b>MAIN</b> Page.
    and use <b>PROTECT ..... ENDPROTECT</b>
    If useful reward.
    Vasanth

  • Display of multiple rows of long text in sap script

    Hello Abapers,
    Is it possible to have a loop inside a sapscript?
    Can you give me a sample code?
    I have tried it on my sapscript but it only shows the last row
    of my internal table.
    This is my source code :
    /: DEFINE &WF_EBELN& = &EKPO-EBELN&
    /: DEFINE &WF_EBELP& = &EKPO-EBELP&
    /: PERFORM GET_ITEM_TEXT IN PROGRAM ZMPU_PO_ORDER
    /: USING &WF_EBELN&
    /: USING &WF_EBELP&
    /: CHANGING &WF_TEXT&
    /: ENDPERFORM
    /:  LOOP AT &WF_TEXT&
    as   &WF_TEXT&
    /:  endloop
    in the zmpu_po_order, the WF_TEXT has 12 lines of data,
    but when sapscript is displayed it only has one line.
    I hope you can help me. Thanks in advance...

    Hi,
    It is not possible using loops in sap text editor .
    YOU CAN USE IN PROGRAM OF FORM.
    reward points

  • Positioning dynamic text in SAP Script windows

    HI all,
    Is there any control command to position DYNAMIC text that comes from a variable into a window...
    Regards,
    Chandra Sekhar

    Hi chandra,
    You can move the text into one variable in the print
    program and in the layout form call this as
    &VAR&.
    Thanks&Regards,
    Siri.

  • How to automatically name files which are saved using " Write to spreadsheet" individually?

    I'm making a program which will save image data (i.e pixel intensity) and the save the data to a text file. Works great but I need it to automatically name each textfile as I will be taking n number of image date in a certain amount of time and don't want to waste time writing each file name.
    Any tips would be hugely appreciated,
    Shack

    Hi Shack,
    you need to create your filename programmatically. As they are just strings you should use string functions to do so!
    Then use "Append Path" to create a full filepath wired to your file function…
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

Maybe you are looking for

  • Can I use BAPI_MATERIAL_MAINTAINDATA_RT to create standard material?

    Hi Friends, I was looking for a BAPI/RFC to create Material Basic, Extended, Classification and Inforecord Data in ECC 6.0 and I found a standard BAPI -  BAPI_MATERIAL_SAVEREPLICA to create/update material, but this BAPI cannot create classfication d

  • Sync Group stuck in 'Processing'

    Can you please reset the following sync group: Status Processing Sync Group ID 3f3f4612-b850-4b5a-bcd0-e0db7c0d9ce7_East US Location East US Subscription ID ca240b2a-97d7-4de8-a7e2-510fe4458740

  • JMS and JDBC Transaction

    I have recently tried using the JMS interface for AQ and I have discovered that the queue connection is a separate JDBC connection even if you create a queue connection using an OracleConnection. Is there a workaround for this? It seems a bit strange

  • My ipod touch 5th gen froze and shut off and won't turn on no matter what I do, HALP

    I went to plug my iPod in and it froze, and then several minutes later went black and I have tried soo many things to get it to turn back on, but it's like it went into a coma. It won't show up when I plug it into my computer and it wont turn on with

  • Confused about wirless internet

    Long story short as possible.  My dad recently got wireless internet through sprint.  Well they told him he had unlimited access but in the very fine print he found out that he was only allowed something like 5 gb of data. Anyway his bill has tripled