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

Regading Including Text in Smart forms

Former Member
0 Likes
609

Hi gurus,

In vf02 they are giving some text . that text is going and saving in STXL table. I want to include this text in smart form.

After choosing include text in General attributes. I am giving

text object is vbbk

Text id is time

language en

but i don't know what i want to give in text name.

so plz help me.

S.Murali Naidu

Edited by: Murali Sreerama on Feb 6, 2008 10:12 AM

5 REPLIES 5
Read only

Former Member
0 Likes
589

Hi,

Use FM "read_text".

Here's a sample piece of code.

DATA: I_F02LINES LIKE STANDARD TABLE OF TLINE WITH HEADER LINE.

data :Lv_name type THEAD-TDNAME.

Lv_name = W_EKKO-EBELN.

CALL FUNCTION 'READ_TEXT'

EXPORTING

CLIENT = SY-MANDT

ID = 'F02'

LANGUAGE = 'E'

NAME = Lv_name

OBJECT = 'EKKO'

TABLES

LINES = I_F02LINES

EXCEPTIONS

ID = 1

LANGUAGE = 2

NAME = 3

NOT_FOUND = 4

OBJECT = 5

REFERENCE_CHECK = 6

WRONG_ACCESS_TO_ARCHIVE = 7

OTHERS = 8

.

READ TABLE I_F02LINES INDEX 1.

regards,

kavitha

Read only

Former Member
0 Likes
589

Hi

This long text

we have to pass

TDID

TDOBJECT

TDNAME

TDSPRAS

to the FM READ_TEXT, then only we will get its content

Award if useful

Narendra

Read only

Former Member
0 Likes
589

u need to pass vbeln to the name field

Madhavi

Read only

Former Member
0 Likes
589

Hi,

Hope this may be helping you,please refer this:

You need to create a text element for this. In the text element type, you have a drop-down where you select include text.

There are corresponding boxes for OBJECT & ID where you type in TEXT & ADRS respectively.

You gotto define 2 global variables: V_TXKOP & V_SPRAS which you have to populate from T024E & EKKO respectively.

Also:

create an include text in the header window

and specify

Text Name - &T024E-TXKOP&

Text Object - TEXT

Text ID - ADRS

Language - &EKKO-SPRAS&

Reward Points if found helpfull..

Cheers,

Chandra Sekhar.

Read only

Former Member
0 Likes
589

Hi,

Please use this code:: (reward pts)

DATA gt_text LIKE tline OCCURS 0 WITH HEADER LINE.

DATA: gt_lines.

REFRESH gt_text.

CALL FUNCTION 'READ_TEXT'

EXPORTING

CLIENT = SY-MANDT

id = 'your text id'

language = sy-langu

name = your billing doc no

object = 'your obj id'

ARCHIVE_HANDLE = 0

LOCAL_CAT = ' '

IMPORTING

HEADER =

tables

lines = gt_text

EXCEPTIONS

ID = 1

LANGUAGE = 2

NAME = 3

NOT_FOUND = 4

OBJECT = 5

REFERENCE_CHECK = 6

WRONG_ACCESS_TO_ARCHIVE = 7

.

IF sy-subrc <> 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

CLEAR: gt_line7,

gt_lines.

  • then to display that

LOOP AT gt_text.

IF NOT gt_text-tdline IS INITIAL.

CONCATENATE gt_line gt_text-tdline INTO gt_line SEPARATED BY space.

ENDIF.

ENDLOOP.

Edited by: rohitaash sharma on Feb 6, 2008 10:22 AM