<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Invoking Text Editor in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209750#M765201</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How to invoke a text editor in a screen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 18 Dec 2007 16:26:23 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-12-18T16:26:23Z</dc:date>
    <item>
      <title>Invoking Text Editor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209750#M765201</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How to invoke a text editor in a screen&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Dec 2007 16:26:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209750#M765201</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-18T16:26:23Z</dc:date>
    </item>
    <item>
      <title>Re: Invoking Text Editor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209751#M765202</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Basically you need to create a container and create an instance of the editor in that container, in this example, I am just creating a docking container on the selection screen, but this could easily be changed to implement in a custom container on a dynpro.  Basically it is the same steps, but the AT SELECTION-SCREEN OUTPUT coding would be the PBO of your screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

report zrich_0001 .

data:
      dockingleft  type ref to cl_gui_docking_container,
      text_editor    type ref to cl_gui_textedit,
      repid type syrepid.

data: begin of header.
        include structure thead.
data: end of header.

data: begin of lines occurs 0.
        include structure tline.
data: end of lines.

data: textlines type table of tline-tdline,
      wa_text type tline-tdline.

parameters: p_check.

at selection-screen output.

  repid = sy-repid.

  create object dockingleft
              exporting repid     = repid
                        dynnr     = sy-dynnr
                        side      = dockingleft-&amp;gt;dock_at_left
                        extension = 1070.

  create object text_editor
              exporting
                   parent     = dockingleft.

start-of-selection.

  call method text_editor-&amp;gt;get_text_as_r3table
     importing
           table              = textlines
     exceptions
           others             = 1.

Loop at textlines into wa_text.
Write:/ wa_text.
endloop.


&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Dec 2007 16:45:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209751#M765202</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-12-18T16:45:10Z</dc:date>
    </item>
    <item>
      <title>Re: Invoking Text Editor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209752#M765203</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello sir,&lt;/P&gt;&lt;P&gt;  Very helpful answer. Can you help me out with this.&lt;/P&gt;&lt;P&gt;  The solution you provided is great but can you tell that &lt;/P&gt;&lt;P&gt;  if i am writting any comment on that and when i will press &lt;/P&gt;&lt;P&gt;  save it shoul ask to create a directory to save the   &lt;/P&gt;&lt;P&gt;  document. Its needed help me wih this. If possible provede&lt;/P&gt;&lt;P&gt;  some code.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Dec 2007 12:48:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209752#M765203</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-20T12:48:05Z</dc:date>
    </item>
    <item>
      <title>Re: Invoking Text Editor</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209753#M765204</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rich,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for your good coding example. It's very helpful. &lt;/P&gt;&lt;P&gt;I have just one question:&lt;/P&gt;&lt;P&gt;How can I set a text to display in the text editor?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I already created the editor and it works fine. I already defined a text with SO10 which I want to display. In my ABAP I read this text using the function module &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;call function 'READ_STDTEXT'
     exporting
          id               = 'ST'
          language         = 'D'
          name             = 'ZPERDIEMS_HELP'
*         USE_AUX_LANGUAGE = ' '
*         USE_THRUCLIENT   = ' '
    importing
         header           = header
     tables
          lines            = lines.
*    EXCEPTIONS
*         ID               = 1
*         LANGUAGE         = 2
*         NAME             = 3
*         NOT_FOUND        = 4
*         REFERENCE_CHECK  = 5
*         OTHERS           = 6
          .
if sy-subrc &amp;lt;&amp;gt; 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I "send" this text to the editor?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance and regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Martin&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;UPDATE: I already found the solution!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: fischerman on Feb 28, 2008 5:25 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 28 Feb 2008 14:12:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/invoking-text-editor/m-p/3209753#M765204</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-28T14:12:40Z</dc:date>
    </item>
  </channel>
</rss>

