Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Issue in Hard Coded texts

Former Member
0 Likes
3,254

Hi,

Previously, I was updated the Hard coded texts to Function Module and Now I wants to use it on the standard text-> y4ap_rtn_cr_policy

From line 280 to 298 we are adding some hard-code text values to the internal table msg_ret-msg. Remove hardcoding and instead read the lines from a standard text. Name of the text would be y4ap_rtn_cr_policy.

How to do that?

Regards,

Ethan

<spoonfeeding, locked by moderator>

Message was edited by: Manish Kumar

11 REPLIES 11
Read only

former_member226225
Contributor
0 Likes
2,976

Hi Ethan,

Create the standard text y4ap_rtn_cr_policy and enter the text in the editor. from the editor we can identify the standard text details

Text Name       Y4AP_RTN_CR_POLICY

Language        EN

Text ID             ST   Standard text

Text Object     TEXT       SAPscript standard texts

Pass these properties to the READ_TEXT fm and read the entries.

and pass to the internal table.

Hope this will be helpful.

Thanks & Regards,

Raghunadh Kodali.

Read only

0 Likes
2,976

Thanks for the reply.. Can you elaborate this...

provide me the steps to do that, then it will be much helpful

Read only

0 Likes
2,976
Read only

rajkumarnarasimman
Active Contributor
0 Likes
2,976

Hi Ethan,

Use FM READ_TEXT to read the standard Text as shown below


DATA:IT_LINE LIKE TLINE OCCURS 0 WITH HEADER LINE,

            V_TDNAME LIKE THEAD-TDNAME VALUE 'Y4AP_RTN_CR_POLICY'.

CALL FUNCTION 'READ_TEXT'

   EXPORTING

     ID                            = 'ST'                         "Check the ID in SO10 in Header Section

     LANGUAGE            = 'EN'

     NAME                      = V_TDNAME

     OBJECT                  = 'TEXT'                  "Check the Object Name in SO10  in Header Section    

   TABLES

     LINES                         = IT_LINE.

Regards

Rajkumar Narasimman

Read only

Former Member
0 Likes
2,976

Hi Ethan,

  1. Create Standard Text with SO10
  2. Call function module READ_TEXT for this new text
  3. Pass the lines from the output table to your table
  4. Either create the Standard Text in all systems DEV, QA, PRD manually or add it to a transport request manually.

Regards,

Klaus

Read only

0 Likes
2,976

HI Klaus,

I want to add the following texts in Standard text through So10.

Can you provide me the steps of how can i add the following texts in SO10?

'If this payment is a charitable contribution or payable to a non-profit organization '.

'qualified under Section 501(c) of the Internal Revenue Code,  do not submit the request '.

'from this tool.  Unless an exemption has been approved, Raytheon Policy 117-RP, '.

'Corporate Contributions and Matching Gifts, states that contributions must be processed'.

'and paid through CyberGrants, Raytheon''s licensed online grants management tool.'.

'Any charitable contributions that cannot be processed through CyberGrants '.

'(i.e. international or in-kind) can be paid via this tool; however, must be recorded in '.

'Cybergrants after the payment has been made, before the end of the fiscal year.'.

Read only

Clemenss
Active Contributor
0 Likes
2,976

Hi Ethan,

use FM READ_TEXT to get the text lines into internal table with line structure TLINE.

Loop at the table

ignore component TDFORMAT, append TDLINE zo your message table.


Regards,


Clemens

Read only

former_member210621
Participant
0 Likes
2,976

Hi,

Go to SO10 and create standard text with following details:

     Text Name - Y4AP_RTN_CR_POLICY

     Language - EN

     Text Id - ST

     Text Object - Text.

To read those lines in your program, Execute FM - 'READ_TEXT' with these details and you will get these lines into internal table - 'LINES'.

Then append the lines of that internal table to msg_ret.

Regards,

Ketan

Read only

former_member1716
Active Contributor
0 Likes
2,976

Hi Ethan,

Go to SO10 and give the details as mentioned above by many experts and create your text. One small point that i can add is while entering the text navigate to standard editor (Navigation: goto -> Change editor) and try to input your text.

There you have an option to maintain the format(Marked in red below) for your texts for each line. Once you press F4 on the format space you will provided with different formats that are allowed to use. This can help you for creating texts in desired format.

After creating this Text you have use the FM READ_TEXT to fetch the text from the SO10. To fetch the input of the FM you can navigate from menu as given below,

Goto-->Header.

This will give the input details of the FM(Marked In Black Below),

Hope this helps you. Please get back for further issues.

thanks,

Satish

Read only

Former Member
0 Likes
2,976

Hi All,

I got to know that I need to create a new Standard Text for ->y4ap_rtn_cr_policy

So how can i add the followings texts to Std texts?

'If this payment is a charitable contribution or payable to a non-profit organization '.

'qualified under Section 501(c) of the Internal Revenue Code,  do not submit the request '.

'from this tool.  Unless an exemption has been approved, Raytheon Policy 117-RP, '.

'Corporate Contributions and Matching Gifts, states that contributions must be processed '.

'and paid through CyberGrants, Raytheon''s licensed online grants management tool.'.

'Any charitable contributions that cannot be processed through CyberGrants '.

'(i.e. international or in-kind) can be paid via this tool; however, must be recorded in '.

'Cybergrants after the payment has been made, before the end of the fiscal year.'.

And how to append the Internal table -> msg_ret to the FM Read_Text ?

Regards,

Ethan

Read only

0 Likes
2,976

When you create Statndard text, one editor will open, you need to write your text on that editor.

And once you execute FM - Read_Text, you will get that text in internal table. you can use that internal table for further processing.