Access of the Text in the TextField

In the following code ,how can I access text in the textfield(i.e object x in the following code) in the place of z in the following code:
BufferedReader br=new BufferedReader(new InputStreamReader(new FileInputStream(z)));
import java.awt.Color;
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import java.io.*;
import java.util.*;
import javax.swing.JTextArea;
public class TextAreaTest1
public static void main(String[] args)
TextAreaFrame frame = new TextAreaFrame();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setVisible(true);
A frame with a text area and buttons for text editing
class TextAreaFrame extends JFrame implements ActionListener
public String TextAreaFrame()
setTitle("TextAreaTest");
setSize(DEFAULT_WIDTH, DEFAULT_HEIGHT);
Container contentPane=getContentPane();
contentPane.setLayout(new GridLayout(5,5,0,0));
buttonPanel = new JPanel();
JPanel textField=new JPanel();
buttonPanel.add(new JLabel("enter"));
// add button to append text into the text area
JTextField x=new JTextField(20);
JButton insertButton = new JButton("Insert");
textField.add(new JLabel("Enter the path"));
// textArea = new JTextArea(8, 30);
// contentPane.add(insertButton);
buttonPanel.add(insertButton);
textField.add(x);
String z=x.getText();
insertButton.addActionListener(this);
contentPane.add(textField);
JPanel group=new JPanel();
          final JTextField a=new JTextField(18);
          JRadioButton b1=new JRadioButton("Start");
          group.add(b1);
          group.add(new JLabel("to"));
          group.add(a);
          JRadioButton b2=new JRadioButton("End");
          group.add(new JLabel("to"));
          group.add(b2,new JLabel("to"));
add(group, BorderLayout.SOUTH);
contentPane.add(buttonPanel);
textArea = new JTextArea(8, 30);
scrollPane = new JScrollPane(textArea);
add(scrollPane);
return(z);
public String getField(){ return x.getTest();}
public void actionPerformed(ActionEvent event)
     try
     BufferedReader br=new BufferedReader(new InputStreamReader(new FileInputStream(z)));
     String l;
                              // String text = a.getText();
System.out.println(+textArea.getLineCount());
     while((l=br.readLine())!=null)
if(l.indexOf("error")==-1)
textArea.append(l+"\n");
textArea.setFont(new Font("Dialog", Font.BOLD, 12));
textArea.setForeground(Color.blue);
System.out.println("this");
/*StringTokenizer st=new StringTokenizer(l);
     //String a="error";
String[] b=new String[10];
     while(st.hasMoreTokens())
                                                       //if(!st.equals("error"))
int i=0;
                              String key=st.nextToken();
                                                       b=key;
                                                       {if(b[i].equals("error"))
                                                       textArea.setFont(new Font("Dialog", Font.BOLD, 12));
                                                       textArea.append(b[i]+"\n");
System.out.println("this");
                                                       i++;}
                                                       else
                                                                 textArea.setFont(new Font("Serif", Font.PLAIN, 12));
                                                                 textArea.append(b[i]+"\n");
System.out.println("that");
                                                       i++;
                                                       //if(!key.equals("error"))
//textArea.append(key+"\n");
                                                       //String val=st.nextToken();
                                                       //textArea.setFont(new Font("Dialog", Font.BOLD, 12));
                                                       //textArea.append(ky+"\n");
                                                       //Font f=new Font("Serif",Font.BOLD,40);
                         //textArea.setColor(new JColorChooser());
     //textArea.append(val+"\n");
                                        if(l.indexOf("error")!=-1)
                                             textArea.setFont(new Font("Serif", Font.PLAIN, 12));
                                             //textArea.setColor(Color.black);
                                             textArea.setForeground(Color.red);
                                             textArea.append(l);
                                   System.out.println("that");
                    catch(Exception ex)
public static final int DEFAULT_WIDTH = 400;
public static final int DEFAULT_HEIGHT = 400;
private JTextArea textArea;
private JScrollPane scrollPane;
private JPanel buttonPanel;
private JButton wrapButton;

1) Swing related questions should be posted in the Swing forum.
2) Don't forget to use the "Code Formatting Tags",
see http://forum.java.sun.com/help.jspa?sec=formatting,
so the posted code retains its original formatting.
3) Use a more descriptive variable name. "x" means nothing.
4) Define the text field reference name as a class variable, not a local variable.

Similar Messages

  • I just statred Flash CC for the first time and it seems that the text within the pop-up window (dialog box) is mis-aligned and not allowing me access to the command buttons, nor all the text. (ie: the NEW Template Box, can't see but 2/3 of the content)

    I just statred Flash CC for the first time and it seems that the text within the pop-up window (dialog box) is mis-aligned and not allowing me access to the command buttons, nor all the text. (ie: the NEW Template Box, can't see but 2/3 of the content) is there a fix to this problem? using 8.1, Monitor is a high res.2560x1440.

    Another View.
    the GUI is so hard to read (so small) I enlarge my Ps UI by the instructions below...which helped a lot.

  • Center the text in the textfield

    Is there a way to center the text in the text field? Specially vertically.

    It seems that when a new text is set, the start position of the text is not recomputed, as the following example demonstrates. Initially all text fields are aligned correctly. But when you then hit the update button, all textfields are updated with a new, longer text which shows the problem. All texts seem to start at the same position which was computed for the previous text and not the recomputed new position for the new text. To temporarily work around this problem, you can reset the alignment of the text fields and then set it back to your desired value. This forces a recomputation of the text start position.
    package textfield.alignment;
    import javafx.application.Application;
    import javafx.event.ActionEvent;
    import javafx.event.EventHandler;
    import javafx.geometry.Pos;
    import javafx.scene.Scene;
    import javafx.scene.control.Button;
    import javafx.scene.control.TextField;
    import javafx.scene.layout.VBox;
    import javafx.stage.Stage;
    public class TextFieldAlignment extends Application {
         TextField lText;
         TextField cText;
         TextField rText;
         public static void main(String[] args) {
              launch(args);
         @Override
         public void start(Stage stage) {
              lText = new TextField("left");
              lText.setAlignment(Pos.BASELINE_LEFT);
              cText = new TextField("center");
              cText.setAlignment(Pos.BASELINE_CENTER);
              rText = new TextField("right");
              rText.setAlignment(Pos.BASELINE_RIGHT);
              Button btn = new Button("update");
              btn.setOnAction(new EventHandler<ActionEvent>() {
                   @Override
                   public void handle(ActionEvent t) {
                        lText.setText("updated left");
                        cText.setText("updated center");
                        rText.setText("updated right");
    //                    applyWorkaround();
              VBox root = new VBox();
              root.getChildren().addAll(lText, cText, rText, btn);
              stage.setScene(new Scene(root, 200, 300));
              stage.show();
         void applyWorkaround() {
              lText.setAlignment(Pos.CENTER);
              lText.setAlignment(Pos.BASELINE_LEFT);
              cText.setAlignment(Pos.CENTER);
              cText.setAlignment(Pos.BASELINE_CENTER);
              rText.setAlignment(Pos.CENTER);
              rText.setAlignment(Pos.BASELINE_RIGHT);          
    }

  • Is there any way to change the font size of the text in the Finder Sidebar?

    This may sound like a bit of a dorky question but here goes nothing...
    I am rather near-sighted and in need of new glasses but I am stuck in a holding pattern until I can get a referral to see my eye doctor. Anyway... I have found myself using the Zoom features far more often and increasing the font size in the Finder for the Item Names & Info.
    The problem that I am facing now, is that the font size of the text in the sidebar is FAR SMALLER than the font size of the text of the actual file names & info.
    +*IS THERE ANY WAY TO INCREASE THE FONT SIZE OF THE TEXT IN THE SIDEBAR??*+
    So far I have looked in:
    *The Finder Preferences
    *The Desktop Preference Pane
    *The Appearance Preference Pane
    *The Seeing Tab of the Universal Access Preference Pane
    And to add to my frustration I have also searched the Mac OS X Help AND all of the posts in this thread (back to 1/1/09) that had the word "sidebar" mentioned in them!!
    +*DOES ANYBODY HAVE ANY OTHER IDEAS?? OR IS THIS ONE AREA THAT I AM OUT OF LUCK BECAUSE APPLE DIDN'T FORESEE THIS ISSUE??*+
    Usually, Apple is really very good about foreseeing any possible trouble (ESPECIALLY when it comes to the area of Accessibility for people w/ disabilities!!)
    I do hope that SOMEBODY can help me on this one!!
    Also, I noticed that the size of the text that is on the Toolbar is also the same ITSY BITSY font size as the text on the sidebar, but I am guessing that there is next to nothing that can be done about that!!
    Thanks a Million!!
    +~Kathryn A.+
    P.S. Here is the link to a screenshot that I took that will illustrate my problem more clearly...
    Icon View Screenshot: http://screencast.com/t/gzDONwN3

    Hi! The only way I know of is changing the screen resolution. Tom

  • Does anyone know how to simply edit the text in the spine of hard cover, 40 page book in the book mo

    Does anyone know how to simply edit the text in the spine of hard cover, 40 page book in the book module? I can click into any other text window and edit and change attributes but I am locked out of editing text when it comes to the spine of the book. I spoke to Blurb support and they referred me to Adobe. I spent 45 minutes with support here - no one knew. I am still waiting for a call back with an answer... not holding my breath as it's been a few hours now. HELP!!!

    Thanks for your reply John. I have experienced all the fiddly aspects you mentioned - these are attributes and although changing them requires the skill of a surgeon's hand - it's the actual editing of the text I can't seem to access anymore. The box just won't allow me to do anything except change attributes. Does that make sense? And it's only on the spine where I am having this issue. Puzzled! I have even rebooted the program and just now the computer - to no avail. 

  • How do I enlarge the text in the toolbar of Safari 5. I need to be able to see the bookmarks that I've placed there. Also I would really like to be able to enlarge the icon size in the Safari toolbar too.

    I am hunting for help in being able to see the text in the toolbar on Safari... also, it would be helpful, too, if I could even enlarge the icons there. I'm dealing with a vision problem and finding that it's quite frustrating when I discover I've clicked on the wrong thing or I can't find what I want to click on up there. Any help will be greatly appreciated!
    Thank you!

    Hi Dorothy,
    Took me awhile to get on a Mac that has Safari 5 on it, (I hate Safari past 3.x, so never update or use it).
    Anyway, I see no options for that at all, though I think it was rumored that 10.4, 10.5, 10.6, 10.7, 10.8 would have it!
    I think your only options are to use the Zoom in Key Combo of CMD & +, or if you don't have a numeric Keypad then CMD+Shift+equal sign, or in System Preferences>Universal Access>Seeing tab, turn Zoom on, then Option+CMD+= will Zoom it in, Option+CMS+minus sign zooms out again.
    There may be some 3rd party system hacks around the text part, but they usually cause problems sooner or later.

  • How to give previleges to just edit the Text within the Portal ?

    Hi all,
    This is our first Portal project and we don't know how to do this.
    In our portal there are 6 or 7 tabs. The first tab (tab-1) is HOME, where there is corporate news to be posted.
    Usually we do all the content modification using ORCLADMIN user.
    Now we want to give access to one end user to edit the text for the corporate news on tab-1.
    But he must not change other part of the Portal.
    How can we do that ?
    Many thanks for your help.
    xtanto

    For order services, contracts and activities set object CRM_ORD_OP as I said.
    For Ibase use CRM_IBASE but with this one it is not possible to set authorizations only for own ibases. Maybe there is some other object for ibases.
    Also for business partner there is no such authorization object to shown only own partners. You have 2 options. To play with object B_BUPA_GRP but that means you will have to maintain group for each responsible employee. Or you implement logic in badi BADI_CRM_BP_UIU_AUTHORITY.

  • When preview my ibook on IPAD the text on the edge of the text box is not visible.  How do I fix that?

    When I preview my ibod created in Ibook Author on my IPAD some of the text on the edge of the text box is not visible.  How do I fix that?

    Does the iOS device connect to other networks? If yes that tend to indicate a problem with your network.
    Does the iOS device see the network?
    Any error messages?
    Do other devices now connect?
    Did the iOS device connect before?
    Try the following to rule out a software problem:                
    - Reset the iOS device. Nothing will be lost
    Reset iOS device: Hold down the On/Off button and the Home button at the same time for at
    least ten seconds, until the Apple logo appears.
    - Power off and then back on your router
    .- Reset network settings: Settings>General>Reset>Reset Network Settings
    - iOS: Troubleshooting Wi-Fi networks and connections
    - Wi-Fi: Unable to connect to an 802.11n Wi-Fi network      
    - iOS: Recommended settings for Wi-Fi routers and access points
    - Restore from backup. See:
    iOS: How to back up
    - Restore to factory settings/new iOS device.
    If still problem and it does not connect to any networks make an appointment at the Genius Bar of an Apple store since it appears you have a hardware problem.
    Apple Retail Store - Genius Bar

  • Can DW CS5 automate the creation of a link based on the text in the link?

    Here's the situation.  I often find myself creating blocks of code like this:
    <a href="home?searchString=some text"><img src="..."></a>
    <a href="home?searchString=some text">some text</a>
    Is there a quick, painless way to type the "some text" part once and have DW automatically update the text in the links?  This information is not dynamically generated, so server-side scripting is not an option.
    Thanks!

    Find & Replace in the source code is the only way I'm aware of.

  • How to change the text in the legend of a graph programmat​ically in labview

    I have many graphs in one plot and want to show the legend the name of the graph (i.e. the filename). How do I change the text in the legend programmatically?

    Create a property node for your graph. Use the property node "Active Plot" to define which plot (or line) you want to rename. Then write the new legend label to the property node "Plot.Name". See attached.
    Tim
    Attachments:
    legend.vi ‏12 KB

  • The text in the tables is hazy when printed in the new version of pages. How can I get this to the same clear text as before?

    In the new version of Pages, the text in the tables are no long clear and sharp as before, they look embedded on all print outs. How can I change this.

    You can do a check for corrupted fonts and other font issues:
    *http://www.thexlab.com/faqs/multipleappsquit.html - Font Book 2.0 Help: Checking for damaged fonts
    *http://www.creativetechs.com/iq/garbled_fonts_troubleshooting_guide.html

  • After upgrading to 10.2.2.12  on windows XP SP3 , itunes does not display any summary info or buttons/options. The buttons work but it does not display the text on the button or the options available.

    I recently upgraded the iTunes software to 10.2.2.12 on my Windows XP laptop. Since then, iTunes stopped displaying the Summary info
    , the text on the buttons, the various drop down options. The buttons seem to be working but I can't tell what that button is supposed to do
    or the option I am selecting. This is preventing me from syncing my photos to the laptop.
    this was not a problem with the previous version of iTunes.
    Actions taken :
    - I tried downloading iTunes again and repairing the install. That did not fix it.
    - Don't want to uninstall it as I am worried that I would lose all the songs and the purchases etc.
    1. Has anyone encountered this ?
    2. Is there a solution for this ?
    Many thanks in advance for your time and help
    Nitin

    bmalones44 wrote:
    b noir, my Windows 7 machine is having the exact same issue as nsadal, and I have already confirmed that all six of the Segoe UI fonts are installed on my computer.  Are any other Windows users having this problem with the 10.2.2.12 iTunes release?
    Yeah it does, although the problem predates version 10.2.2.12. It's been around since earlier-on in the version 10s (at least).
    It's usually Segoe UI font trouble on the Windows 7 systems too. Unfortunately, the Vortical troubleshooting technique only works on XP and Vista systems, so dealing with the issue on a Windows 7 system is trickier. (There's a bunch of different possible issues relating to the fonts that could be in play, and so the treatment tends to depend on which issue in particular you've got with the Segoe_UI fonts.)
    For discussions of various Windows 7 variations of the "Missing text" thing, and possible treatments, see the following (unfortunately, rather long) topic:
    iTunes 10.1 Missing Text

  • In popup step how do I get the "text on the button" in the report rather than button index?

    (1)
    How do I configure the POPUP step in "SEQ MAIN.seq" to execute the second
    step (IS OUT PUT IS 20?) in "SEQ 1.seq" when "IS OUT PUT IS 20?" button
    hit and execute the third step (IS OUT PUT IS 30?) in "SEQ 1.seq" when "IS
    OUT PUT IS 30?" button hit.
    (2)
    In popup step how do I get the "text on the button" in the report rather than button index?
    File attached
    Attachments:
    test_stand.zip ‏32 KB

    The handle to the Step.Button1Label gets you the data, but there are several ways to get it into the actual report.
    The easiest is to use the reporttext.
    In a post expression, you can use something like
    Step.Result.ReportText = Evaluate("Step.Button" + Str(Step.Result.ButtonHit) +"Label")
    and then the default report generation will include it in the report. Otherwise, you need to get the text into the Resultlist by various means (check the user manual, or the TestStand II customisation course) and handle the report generation yourself inside of the appropriate sequence in the process model.
    Just my 2cents
    S.
    // it takes almost no time to rate an answer
    Attachments:
    IncludeButtonTextInReport2_0.seq ‏18 KB

  • I'm using Acrobat Pro 11. When printing an email to PDF most of the time it cuts off the text on the right margin. Setting look OK and I've moved things around on the email, but that doesn't seem to make any difference. Is there an Adobe setting I'm missi

    Like I said above, print to Adobe pdf and it wants to cut off the text on the right margin. I can't see to find a setting that changes this. Any ideas??

    OK, so I have now found that this is apparently normal for iTunes, to only accept mpeg 4 movie files, all the searching I did before I must have worded it wrong because I couldn't find anything about this, incredibly. Had been looking for why iTunes won't take all the files it previously did, like if it had been changed, and it hasn't, it's allegedly always taken only mpeg 4 files. Also I had been searching for why iTunes crashes every time I try and add/import anything but mpeg 4 files, and even sometimes with mpeg 4 files. That isn't normal, it's supposed to just do nothing apparently as I've just found out. So for these reasons I didn't find the answer despite my searching all over the web.
    So I guess that answers my own question now, but I'm still perplexed as to why I absolutely, definitely, without any doubt, had several hundred movies of a few different video file types loaded, accessible and playable in my iTunes library that everything here claims iTunes never accepted. It apparently shouldn't have been possible for me to have done this, but for probably 10 years it's been this way.
    Perhaps since I don't remember adding these files to iTunes anymore recently than maybe 6 or 7 years ago, the iTunes back then did accept all kinds of file types? Or could I have somehow had some video codecs or software that expanded the capability of my movie players like Quicktime Player that unwittingly also allowed iTunes to take those files as well? All I know is somehow it worked! So now my question is how did I have it working before, so that maybe I can make it work again.

  • Is there a way of just changing the text to the main menu..but not the submenus?

    Is there a way of just changing the text to the main
    menu..but not the submenus?
    Also i have looked at in the browser and when i glide over
    the menu catergories or click on them they dont show the
    submenu...what can i do to solve this?

    Does the example described at
    http://labs.adobe.com/technologies/spry/articles/menu_bar/index.html
    work for you?
    What are you doing that's different from the example?
    When you say you just want to change the text of the main
    menu without changing the submenus, do you mean you want to do so
    dynamically, at some later stage after the page has loaded?
    If so, you could try retrieving the main menu elements you
    want to update from the DOM and updating them from your script's
    event handler for whatever event it is that you want to update them
    in response to. This presumes the widget will detect this and
    update appropriately, which I can't say for sure since I haven't
    actually tried it.
    Hope that helps!
    Rob

  • How to clear the text in the Text Editor

    Hi all,
    I created a Text editor and also i am having language field in the screen.
    whenever i change the language auomatically the text has to change when the text exists for that
    language.
    this is working fine, but when the Text exist , the text editor should be blank.
    But it is carrying the Previous editor text itself into it .
    How to clear the text in the Editor.
    Regards,
    Madhavi

    Hello Madhavi
    The simple report ZUS_SDN_TEXTEDIT_CONTROL shows how to switch the texteditor contents when changing the language.
    *& Report  ZUS_SDN_TEXTEDIT_CONTROL
    *& Thread: how to clear the text in the Text Editor
    *& <a class="jive_macro jive_macro_thread" href="" __jive_macro_name="thread" modifiedtitle="true" __default_attr="1145272"></a>
    *& By default the itab GT_OUTTAB contains texts in DE and EN.
    *& To switch the language directly enter into the command window:
    *& LANGU=DE, LANGU=EN or LANGU=FR
    REPORT  zus_sdn_textedit_control.
    TYPE-POOLS: abap.
    TYPES: ty_t_text     TYPE TABLE OF as4text
                         WITH DEFAULT KEY.
    TYPES: BEGIN OF ty_s_outtab.
    TYPES: language TYPE spras.
    TYPES: text     TYPE ty_t_text.
    TYPES: END OF ty_s_outtab.
    TYPES: ty_t_outtab    TYPE STANDARD TABLE OF ty_s_outtab
                          WITH DEFAULT KEY.
    DATA: gt_outtab       TYPE ty_t_outtab,
          gs_outtab       TYPE ty_s_outtab.
    DATA: gd_language     TYPE spras.
    DATA: go_docking      TYPE REF TO cl_gui_docking_container,
          go_textedit     TYPE REF TO cl_gui_textedit.
    DATA: gd_okcode       TYPE ui_func,
          gd_repid        TYPE syst-repid.
    START-OF-SELECTION.
      PERFORM fill_texts.
      gd_language = syst-langu.
      PERFORM init_controls.
    * Link the docking container to the target dynpro
      gd_repid  = syst-repid.
      CALL METHOD go_docking->link
        EXPORTING
          repid                       = gd_repid
          dynnr                       = '0100'
    *      CONTAINER                   =
        EXCEPTIONS
          OTHERS                      = 4.
      IF sy-subrc NE 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      PERFORM set_text_editor.
    * NOTE: dynpro does not contain any elements
      "       ok-code => GD_OKCODE
      CALL SCREEN '0100'.
    * Flow logic of dynpro (does not contain any dynpro elements):
    *PROCESS BEFORE OUTPUT.
    *  MODULE STATUS_0100.
    *PROCESS AFTER INPUT.
    *  MODULE USER_COMMAND_0100.
    END-OF-SELECTION.
    *&      Module  STATUS_0100  OUTPUT
    *       text
    MODULE status_0100 OUTPUT.
      SET PF-STATUS 'STATUS_0100'.  " contains push button "DETAIL"
    *  SET TITLEBAR 'xxx'.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  USER_COMMAND_0100  INPUT
    *       text
    MODULE user_command_0100 INPUT.
      TRANSLATE gd_okcode TO UPPER CASE.
      CASE gd_okcode.
        WHEN 'BACK'  OR
             'EXIT'  OR
             'CANC'.
          SET SCREEN 0. LEAVE SCREEN.
        WHEN 'LANGU=DE' OR
             'LANGU=EN' OR
             'LANGU=FR'.
          PERFORM get_text_editor.
          SPLIT gd_okcode AT '=' INTO gd_okcode gd_language.
          PERFORM set_text_editor.
        WHEN OTHERS.
      ENDCASE.
      CLEAR: gd_okcode.
    ENDMODULE.                 " USER_COMMAND_0100  INPUT
    *&      Form  FILL_TEXTS
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM fill_texts .
    * define local data
      DATA: ld_string   TYPE string.
      gs_outtab-language = 'EN'. REFRESH: gs_outtab-text.
      ld_string = 'Good morning'.
      APPEND ld_string TO gs_outtab-text.
      APPEND gs_outtab TO gt_outtab.
      gs_outtab-language = 'DE'. REFRESH: gs_outtab-text.
      ld_string = 'Guten Morgen'.
      APPEND ld_string TO gs_outtab-text.
      APPEND gs_outtab TO gt_outtab.
      gs_outtab-language = 'FR'. REFRESH: gs_outtab-text.
      ld_string = space.
      APPEND ld_string TO gs_outtab-text.
      APPEND gs_outtab TO gt_outtab.
    ENDFORM.                    " FILL_TEXTS
    *&      Form  INIT_CONTROLS
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM init_controls .
      CREATE OBJECT go_docking
        EXPORTING
          parent                      = cl_gui_container=>screen0
    *      repid                       =
    *      dynnr                       =
    *      side                        = dock_at_left
    *      extension                   = 50
    *      style                       =
    *      lifetime                    = lifetime_default
    *      caption                     =
    *      metric                      = 0
          ratio                       = 90
    *      no_autodef_progid_dynnr     =
    *      name                        =
        EXCEPTIONS
          cntl_error                  = 1
          cntl_system_error           = 2
          create_error                = 3
          lifetime_error              = 4
          lifetime_dynpro_dynpro_link = 5
          OTHERS                      = 6.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      CREATE OBJECT go_textedit
        EXPORTING
    *      max_number_chars       =
    *      style                  = 0
    *      wordwrap_mode          = wordwrap_at_windowborder
    *      wordwrap_position      = -1
    *      wordwrap_to_linebreak_mode = false
    *      filedrop_mode          = dropfile_event_off
          parent                 = go_docking
    *      lifetime               =
    *      name                   =
        EXCEPTIONS
          error_cntl_create      = 1
          error_cntl_init        = 2
          error_cntl_link        = 3
          error_dp_create        = 4
          gui_type_not_supported = 5
          OTHERS                 = 6.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " INIT_CONTROLS
    *&      Form  SET_TEXT_EDITOR
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM set_text_editor .
      BREAK-POINT.
      CLEAR: gs_outtab.
      READ TABLE gt_outtab INTO gs_outtab
           WITH KEY language = gd_language.
      CALL METHOD go_textedit->set_text_as_stream
        EXPORTING
          text            = gs_outtab-text
        EXCEPTIONS
          error_dp        = 1
          error_dp_create = 2
          OTHERS          = 3.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " SET_TEXT_EDITOR
    *&      Form  GET_TEXT_EDITOR
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM get_text_editor .
      CLEAR: gs_outtab.
      CALL METHOD go_textedit->get_text_as_stream
        EXPORTING
          only_when_modified     = cl_gui_textedit=>true
        IMPORTING
          text                   = gs_outtab-text
    *      is_modified            =
        EXCEPTIONS
          error_dp               = 1
          error_cntl_call_method = 2
          OTHERS                 = 3.
      IF sy-subrc <> 0.
    *   MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *              WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      MODIFY gt_outtab FROM gs_outtab
        TRANSPORTING text
        WHERE ( language = gd_language ).
    ENDFORM.                    " GET_TEXT_EDITOR
    Regards
      Uwe

Maybe you are looking for

  • Powerbook Lower Memory Slot Issue, what are my options?

    Hi there, I have a Powerbook G4 1.5ghz that I purchased in October of 2004. I had no problems with it until after upgrading the RAM to 2 x 512mb chips and then installing Tiger which resulted in me later notcing the missing RAM and learning about the

  • Can I have more than one authorisation on one Macbook?

    Trying to figure out how to amalgamate two ageing laptops' content... I've read loads on how to get the two libraries (my wife's and mine) onto a new MBP, but I guess I'm still a bit scared that I'll find when I try to authorise it to play music from

  • Syncing iPad to iPod from iTunes on external hard drive

    I had all my music stored on my laptop but was running out of space so I transferred it all to an external hard drive. That's when everything went pear shaped! Tried to sync it all but messed it up. Now I have all songs on iPad, but it won't sync new

  • How we can make MVT 551 (scrapping) a 2 step process

    Dear all, Is it possible to make the movement type 551 (scrapping) a 2 step process similar to 313,315 or park and post in accounts. The requirement is one department will make the document and another department will post that document What are the

  • AdBlocker no longer functions...

    As Safari version hasn't changed (5.1), I don't understand why AdBlocker is no longer able to hide all ads in web pages. Same situation occured for Firefox. I think Apple has put some secret code disabling AdBlocker and similar third parties apps. Do