Application Development 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: 

CL GUI TEXTEDIT add text and store user details.

Former Member
0 Kudos

Hi gurus,

Here is my scenario:

I have created a PM notification that displays a subscreen. On the subscreen there is a custom control using CL GUI TEXTEDIT.

I am able to write text here and it is then saved to a SAP longtext object by my logic.

Now the problem is I want CL GUI TEXTEDIT to behave like the standard SAP long text fields found on a notification e.g 'Subject Long Text'.

The 'Subject Long Text' field behaves as follows: when a user edits the longtext their username and the date are stored into the longtext as part of the change. Once saved this text can not be modified and becomes display only. However.. more text may be added to the field and saved in the same way. Each time additional text is added by some user that persons username and the date of the change are Incorporated into the field above the text they add.

How can I replicate this with CL GUI TEXTEDIT ??? Any sample code??? or another soultion?

Thanks in advance.

1 REPLY 1

Former Member
0 Kudos

Hi Scott,

I guess you can do one of these.

1) Read the text.

    Then append the internal table of read data with your own custom user log (sy-uname etc.)     

    Then save/refresh text

2) Create text object with ZXXXNX (See below link).

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b036dbfc-29dd-2a10-2aba-ccd1c4c96...

Few sample codes of Text editor:

http://wiki.sdn.sap.com/wiki/display/ABAP/Text+Editor+Insert+%2C+Change+%2C+Display

http://wiki.sdn.sap.com/wiki/display/ABAP/Create+Text+Editor+Source+code

http://wiki.sdn.sap.com/wiki/display/Snippets/Text-Editing+from+Notes+-+Logic+to+HTML+Standard+text+...   (check method add_historyline)

Regards,

Nisha Vengal.