Get long text of a message
I have created message class in tran. se91 and i want to get the long text of a particular message
in these message class.
how can i get the long text of the message dynamiclly in the program code?
thanks in advance,
Noa
Hi,
you can use Function Module MESSAGE_TEXT_BUILD as:
CALL FUNCTION 'MESSAGE_TEXT_BUILD'
EXPORTING
msgid = g_msgid
msgnr = g_msgno
msgv1 = g_msgv1
IMPORTING
message_text_output = g_message.
Message text will be in g_message.
regards,
Neha
Similar Messages
-
I switched to a samsung galaxy 5 AND MY friends w iphones cannot get my text because i message is holding them hostage!!! help!
Ive done everything that a t and t have told me to do. text 48369 ive turned off i message on all devices and i still can't recieve text from iphone friendsksfm3 wrote:
I did all of those things prior to posting on how to fix it. None of these worked. I changed my password.
For what silly reason would any intelligent person believe that changing an Apple ID password would have any affect on iMessage?
From the link provided:
If you can't access your iPhone, you no longer have it, or you can't deactivate iMessage after you try the above steps, please contact Apple Support.
Performing these tasks won't deregister iMessage:
Logging into My Support Profile and changing your password or removing your phone number
Sending an SMS text message STOP to 48369
Resetting your network settings
Changing your Apple ID password -
How to get Long text in report from FBL3N
Hi,
I need to get Long Text from FBL3N (G/L Account Line Item Display) in my report.Can anyone tell me in which table it is stored?Hi
These long texts are not stored completely in any tables
where as the parameters of these texts like OBJECT,OBJECTNAME and ID, LANGUAGE are stored in STXH table
You have to pass these 4 parameters to the fun module READ_TEXT and to fetch the text.
Double click on the long text will goes to text editor
from menu GOTO-> HEADER you will see the above 4 paramters
see the doc of READ_TEXT fun module
READ_TEXT
READ_TEXT provides a text for the application program in the specified work areas.
The function module reads the desired text from the text file, the text memory, or the archive. You must fully specify the text using OBJECT, NAME, ID, and LANGUAGE. An internal work area can hold only one text; therefore, generic specifications are not allowed with these options.
After successful reading, the system places header information and text lines into the work areas specified with HEADER and LINES.
If a reference text is used, SAPscript automatically processes the reference chain and provides the text lines found in the text at the end of the chain. If an error occurs, the system leaves the function module and triggers the exception REFERENCE_CHECK.
Function call:
CALL FUNCTION 'READ_TEXT'
EXPORTING CLIENT = SY-MANDT
OBJECT = ?...
NAME = ?...
ID = ?...
LANGUAGE = ?...
ARCHIVE_HANDLE = 0
IMPORTING HEADER =
TABLES LINES = ?...
EXCEPTIONS ID =
LANGUAGE =
NAME =
NOT_FOUND =
OBJECT =
REFERENCE_CHECK =
WRONG_ACCESS_TO_ARCHIVE =
Export parameters:
CLIENT
Specify the client under which the text is stored. If you omit this parameter, the system uses the current client as default.
Reference field: SY-MANDT
Default value: SY-MANDT
OBJECT
Enter the name of the text object to which the text is allocated. Table TTXOB contains the valid objects.
Reference field: THEAD-TDOBJECT
NAME
Enter the name of the text module. The name may be up to 70 characters long. Its internal structure depends on the text object used.
Reference field: THEAD-TDNAME
ID
Enter the text ID of the text module. Table TTXID contains the valid text IDs, depending on the text object.
Reference field: THEAD-TDID
LANGUAGE
Enter the language key of the text module. The system accepts only languages that are defined in table T002.
Reference field: THEAD-TDSPRAS
ARCHIVE_HANDLE
If you want to read the text from the archive, you must enter a handle here. The system uses it to access the archive. You can create the handle using the function module ACHIVE_OPEN_FOR_READ.
The value '0' indicates that you do not want to read the text from the archive.
Reference field: SY-TABIX
Default value: 0
Import parameters:
HEADER
If the system finds the desired text, it returns the text header in this parameter.
Structure: THEAD
Table parameters:
LINES
The table contains all text lines that belong to the text read.
Structure: TLINE
Exceptions:
ID
The text ID specified in the parameter ID does not exist in table TTXID. It must be defined there together with the object of the text module.
LANGUAGE
The parameter LANGUAGE contains a language key that does not exist in table T002.
NAME
The parameter NAME contains the name of a text module that does not correspond to the SAPscript conventions.
Possible errors:
The field contains only blanks.
The field contains the invalid characters * or ,.
OBJECT
The parameter OBJECT contains the name of a text object that does not exist in table TTXOB.
NOT_FOUND
The system did not find the specified text module.
REFERENCE_CHECK
The text module to be read has no text lines of its own but refers to the lines of another text module. This reference chain can include several levels. For the current text, the chain is interrupted, that is, one of the text modules referred to in the chain no longer exists.
WRONG_ACCESS_ TO_ARCHIVE
The exception WRONG_ACCESS_TO_ARCHIVE is triggered if an archive is accessed using an incorrect or non-existing archive handle or an incorrect mode (that is, read if the archive is open for writing or vice versa).
<b>Reward points for useful Answers</b>
Regards
Anji -
Problem in getting long text in Cash receipt.
Hi all,
I want long text in my form print but as a programming i am not getting long text in description Field I am getting short text. So can you please kindly tell me when we entered long text in transaction FBCJ this long text save in which table. And how can i fetch this data in my smartforms.
Thanks in Advance.Hi Keyur,
when you see the detail text in the transaction, use menu goto -> header. Here you see the details to use for an include staement in sapscript. Note that the text name may be a concateneation of client and document number. Prepare the details in print program, fill in variables to be used in sapscript.
Hope these details are enough.
Regards,
Clemens -
Getting Long Text of a Field Label
Hi Friends,
I have requirement in which , based on the filed I need get the Long text of the data element.by default I am able to access the medium text of the data element. is there any function-module for getting Long text?
Regards,
Xavier.PHi Xavier,
check this
Storing long text data
hope it helps you.
Regards! -
Hello experts,
I have a scenario wherein I need to display a warning status message at the bottom of the screen. When the user clicks on that message, the long text of the message should contain certain extra information.
For example: I give the warning status message like: "Some entries are invalid".
Once the user clicks this message, a new window opens up, which says:
Entry 1 is invalid.
Entry 2 is invalid.
Entry 3 is invalid.
Entry 4 is invalid.
How can I achieve this result?
Thanks,
Ajay.Hello Ajay.
goto the message class in se91 -> here message class is ZARP -- > select the particular message number like '001' click on long text ( CTRL + F7 ) , write the appropriate text u want , and in program while you write the message like
REPORT ZABY message-id ZARP.
message W001. " if user double clicks on that message, the long text of the message displays
Regards,
Aby -
Extracting long text of a message
Hi,
I have a message in a message class with a long text.I want to extract this longtext in my program. Is there any method to access/extract lontext of a message of a mesasge class? i.e if i can give the message class and message id as input?Function module DOCU_GET_FOR_F1HELP will get you the message's long text. You'll need to set the ID to NA, and the rest of the parameters are the language and your message id and number.
The long text is returned in a table.
Regards,
Nick -
hello All,
I created a new message in the message class ME. I also created a long text for that particular message. But when i use the message in a program long text is not dispalayed properly. Pls give some inputs.
Thnaks
DuraiThe<b> long texts</b> of a document are stored in a encrypted format in the STXH and STXL tables, where STXH stores the header information of the long text like <b>TDOBJECT,</b> which indicates which text object the long text belongs to, TDID which indicates the Text <b>ID and TDNAME</b> which is the actual name of the long text.
As these texts are stored in a encrypted format, the text cannot be read using a SELECT statement. You will have to use the function <b>READ_TEXT.</b> The easiest way of getting to know the parameter values is to go to a document, open the long text in a full screen mode. For example, when you wan to see the long text for a Purchase order, go to transaction ME23n. Assume, you want to see the parameters for the Header Text. In the first Tab Strip Control, click on the Texts tab and select the Header Text node on the left hand side, which will display the text on the right hand side. Now, double click on the text editor on the right hand side. This will open the text in the full screen mode. In the menu<b> Go To --> Header, you</b> should be able to see the values for all the three parameters we discussed above. We will have to do the same thing for whichever text parameters we want to see.
CALL FUNCTION 'READ_TEXT'
EXPORTING
* CLIENT = SY-MANDT
ID =
LANGUAGE =
NAME =
OBJECT =
* ARCHIVE_HANDLE = 0
* LOCAL_CAT = ' '
* IMPORTING
* HEADER =
TABLES
LINES =
* EXCEPTIONS
* ID = 1
* LANGUAGE = 2
* NAME = 3
* NOT_FOUND = 4
* OBJECT = 5
* REFERENCE_CHECK = 6
* WRONG_ACCESS_TO_ARCHIVE = 7
* OTHERS = 8
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
reward points if it is usefull ....
Girish -
Hi,
I need to get the long text that we maintained in CJ20n tcode under long text at project level. I need to display the same in Script layout or report. I didnot find any table or functional module to get it. please help me out.
regards,
ChandraHi
Double click on the Long text, it will take you to Text editor
from the Menu GOTO-> HEADER
you will find the OBJECT,ID,OBJECTNAME and LANGUAGE parameters for that lang text which are to be passed to the READ_TEXT fun module
for displaying it on report use the above fun module and fetch the text in IT_LINES internal table and write it on report output
You can also see the doc of the read_text
READ_TEXT
READ_TEXT provides a text for the application program in the specified work areas.
The function module reads the desired text from the text file, the text memory, or the archive. You must fully specify the text using OBJECT, NAME, ID, and LANGUAGE. An internal work area can hold only one text; therefore, generic specifications are not allowed with these options.
After successful reading, the system places header information and text lines into the work areas specified with HEADER and LINES.
If a reference text is used, SAPscript automatically processes the reference chain and provides the text lines found in the text at the end of the chain. If an error occurs, the system leaves the function module and triggers the exception REFERENCE_CHECK.
Function call:
CALL FUNCTION 'READ_TEXT'
EXPORTING CLIENT = SY-MANDT
OBJECT = ?...
NAME = ?...
ID = ?...
LANGUAGE = ?...
ARCHIVE_HANDLE = 0
IMPORTING HEADER =
TABLES LINES = ?...
EXCEPTIONS ID =
LANGUAGE =
NAME =
NOT_FOUND =
OBJECT =
REFERENCE_CHECK =
WRONG_ACCESS_TO_ARCHIVE =
Export parameters:
CLIENT
Specify the client under which the text is stored. If you omit this parameter, the system uses the current client as default.
Reference field: SY-MANDT
Default value: SY-MANDT
OBJECT
Enter the name of the text object to which the text is allocated. Table TTXOB contains the valid objects.
Reference field: THEAD-TDOBJECT
NAME
Enter the name of the text module. The name may be up to 70 characters long. Its internal structure depends on the text object used.
Reference field: THEAD-TDNAME
ID
Enter the text ID of the text module. Table TTXID contains the valid text IDs, depending on the text object.
Reference field: THEAD-TDID
LANGUAGE
Enter the language key of the text module. The system accepts only languages that are defined in table T002.
Reference field: THEAD-TDSPRAS
ARCHIVE_HANDLE
If you want to read the text from the archive, you must enter a handle here. The system uses it to access the archive. You can create the handle using the function module ACHIVE_OPEN_FOR_READ.
The value '0' indicates that you do not want to read the text from the archive.
Reference field: SY-TABIX
Default value: 0
Import parameters:
HEADER
If the system finds the desired text, it returns the text header in this parameter.
Structure: THEAD
Table parameters:
LINES
The table contains all text lines that belong to the text read.
Structure: TLINE
Exceptions:
ID
The text ID specified in the parameter ID does not exist in table TTXID. It must be defined there together with the object of the text module.
LANGUAGE
The parameter LANGUAGE contains a language key that does not exist in table T002.
NAME
The parameter NAME contains the name of a text module that does not correspond to the SAPscript conventions.
Possible errors:
The field contains only blanks.
The field contains the invalid characters * or ,.
OBJECT
The parameter OBJECT contains the name of a text object that does not exist in table TTXOB.
NOT_FOUND
The system did not find the specified text module.
REFERENCE_CHECK
The text module to be read has no text lines of its own but refers to the lines of another text module. This reference chain can include several levels. For the current text, the chain is interrupted, that is, one of the text modules referred to in the chain no longer exists.
WRONG_ACCESS_ TO_ARCHIVE
The exception WRONG_ACCESS_TO_ARCHIVE is triggered if an archive is accessed using an incorrect or non-existing archive handle or an incorrect mode (that is, read if the archive is open for writing or vice versa).
IN SCRIPTS you can use the INCLUDE statement to print the Long texts
/: INCLUDE TEXT<name> ID <id> Lang <en> paragraph <za>
Regards
Anji -
How to get the text of a message class
Hi,
I have a message class and added few message(with attributes) to that class.
Now i want to read the text of the message based on the attributes and
the message no.
Example:
Message 19 is - Where is &1. Where is &1. Where is &1. Where is &1.
Information that i have :
ls_msg-msgty = 'S' .
ls_msg-msgid = 'AP_JATT_TDC_MSG_CL'.
ls_msg-msgno = 19 .
ls_msg-msgv1 = 'A'.
ls_msg-msgv1 = 'B'.
ls_msg-msgv1 = 'C'.
ls_msg-msgv1 = 'D'.
From the info that i have i want the text
Where is A. Where is B. Where is C. Where is D.
Is there any function modules which will provide me these details?
Regards,
Bikash.HI
You can get the Text based on the Message attributes using the FMs
FORMAT_MESSAGE
MESSAGE_TEXT_BUILD.
Use any one of them..
It will work for u...
<b>reward if Helpful</b> -
How to generate long text of the message during run time?
Hi guys,
I have a question like in the subject. Someone could help me with that? I need to put some kind of log after transaction execution into message's long text, so that the short text displays only some short information and long text contains detailed description of the problem, but returned by program. And the log can be long, so it is not enough to put there only some parameter.
Thanks and kind regards,
MarcinHi,
Do you want to change the label of the parameter??
Check this example..
PARAMETERS: p_check AS CHECKBOX USER-COMMAND usr.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(15) v_text FOR FIELD p_land1.
PARAMETERS: p_land1 TYPE t005-land1.
SELECTION-SCREEN END OF LINE.
AT SELECTION-SCREEN OUTPUT.
IF p_check = 'X'.
v_text = 'From country'.
ELSE.
v_text = 'To country'.
ENDIF.
Regards,
Ramesh. -
How to Get Long text of a material?
Hi Friends,
Could you please help me, in getting the Long text of a Material?
if any sample code is available, kindly provide.
Regards,
Xavier.Phere you have a working code snippet: the longtext is stored in table lines.
tables: stxh.
data: lines like tline occurs 0 with header line.
data: ID LIKE THEAD-TDID,
LANGUAGE LIKE THEAD-TDSPRAS,
NAME LIKE THEAD-TDNAME,
OBJECT LIKE THEAD-TDOBJECT.
clear: lines[].
select single * from stxh into stxh
where tdname eq mara-matnr
and tdid eq 'GRUN'
and tdobject eq 'MATERIAL'
and tdspras eq 'EN'.
ID = stxh-tdid.
OBJECT = stxh-tdobject.
NAME = stxh-tdname.
CALL FUNCTION 'READ_TEXT'
EXPORTING
ID = id
LANGUAGE = 'EN'
NAME = name
OBJECT = object
TABLES
LINES = lines
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
WRONG_ACCESS_TO_ARCHIVE = 7
OTHERS = 8.
regards tony -
Hi Everyone,
I have a requirement where I need to display the Longtext that is displayed in transaction IW33.
Its is not the KTEXT feild pf table AUFK as this feild contains data upto 40 characters.
My requirement is to fetch all the characters that are in Longtext.
There must be a table where the long text is saved.
Please let me the table ???
Regards,
RajPress Display Text button in front of long text.You will go to editor.Then from the munubar select Go to->Header.Use these header details:
Text Name <Order no.>
Language EN
Text ID KOPF Order header text
Text Object AUFK Order text
Pass this to FM READ_TEXT.You can also refer the tables STXH and STXL but i guess FM will solve your problem. -
Problem in Getting Long Text After uploading LT using CREATE_TEXT in CORS
Hi Gurus,
i am uploading long text for Reason for cancellation in CORS Transaction through CREATE_TEXT.
after uploading this text by using this FM CREATE_TEXT i am seeing the long text what ever i uploaded through CREATE_TEXT , i am unable to see first 40 characters of that long text.
if anybody faced this problem earlier please guide me to resolve this problem.
Thanks & Regards
Venkata Ramesh JHi,
can you please check this link
Replacing the text created in create_text
Thanks
durga.K -
Hi,
Is it possible to retrieve the long text in STXH and STXL by SQL instead of READ_TEXT FM?? How can i covert the HEX text back to normal text??
Regards,
KitHi,
1. Only the way to Read long text is use the function module READ_TEXT for which u need to pass TEXTOBJECT, TEXTID, TEXTLANGUAGE AND ONEMORE(I FORGET).
Because the STXL and STXH these tables are cluster tables in which data stored in LRAW field which is in RAW format which u can not understand and our normal SQL can also.
2. so u can read most of cluster tables by Function modules only.
3. u can modify or saved by save_text
Maybe you are looking for
-
For the past couple of weeks now I've been plagued with the problem of not being able to properly upgrade my flash player to version 9. I'd get pass the installation, sure, but they'd be corrupted installations. I can't view some flash websites and t
-
Set snapshot expsure time LuCam
Hello - I am using a Lumenera Lm-075 USB camera to try to take long (~100s of ms) exposure pictures using Labview. I have the Lumenera instrument drivers for Labview and can take pictures, but cannot control the exposure time (as described below).
-
Ipad won't restore gets error occurred 2009
Tried to backup and update to 7.0ios, but ipad2 could not be restore an unknow error occurred (2009) Updated iTunes software shutdown and restarted tried again, still in a recovery mode operating system is windows 7 dell can anyone help, the apple st
-
HT201405 how to solve time machine error-1
how to solve time machine error-1
-
When installing flash player I recieve error message stating "internet explorer script error," and flash player fails to install.