How to control the cursor position in the Table control in Module pool

Hi,
Can any body tell me how to change the cursor positon from last field of the first record to the
first field of the second record , when user presses enter in the last field in the module pool
programming.
Thanks

Hi,
Please avoid posting duplicate posts.
Re: how to get the cursor position from screen in module pool program
Nag

Similar Messages

  • How to get the cursor position in the text edit box?

    Hi, all.
    I want to get the cursor position in the text edit box
    to insert some data.
    But I don't know how to get.
    Can someone give me some advice?
    BestRegard.
    Miya.

    Hi Miya,
    Write your own textSelectionSuite for this.
    and use ITextTarget->GetRange() function.
    Thanks and Regards,
    Yopangjo.

  • Setting the cursor on a particular input field in module pool

    Hi,
    I am working on an abap module program, the requirement is the cursor should be placed on a particular field at run time.
    In detail:  Table contains zserialno primary key field, zemailid of char type.
    Screen design: 1st text input field is zserialno
                             2nd field zemailid is splitted into 3 input text fields.
    For 2nd field zemailid 1st input field allows user to enter his/her email name, 2nd input field is an drop down which contains domain names and 3rd field is an empty field which is to be triggered on user action.
    example: zemailid- 1st input field  XYZ 2nd input field conatains @gm../@yah....and others. If user selects on others value in drop down of 2nd input field, the cursor should point the 3rd input field which allows the  user to enter his/her other domain.
    I used
    SET CURSOR FIELD <3rd inpu field namet>.
    , but the cursor pointing the key field of the table zserialno even the input field of zserialno was provided with a value.
    Any idea on this is appreciated.
    Edited by: Sona_abaper on May 7, 2011 5:34 PM

    Hi Sona,
    F1:
    Effect:
    During PBO processing, this statement sets the cursor in the screen layout of the current screen. The cursor can be positioned by entering a screen element after FIELD or by entering a specific position using col and lin. Outside of PBO processing, the cursor is positioned in the next list displayed on the screen.
    If the SET CURSOR statement is not specified, depending on the definition of the screen, the cursor is set according to the following hierarchy:
        On the cursor position determined statically in the screen properties,
        On the first input field of the screen,
        On the first screen element of the screen,
        On the command field in the systemtoolbar.
    The latter also applies if the command field in the system toolbar is not displayed.
    I'm convinced your code works as designed.
    Let us know your PBO module and code.
    Regards,
    Clemens

  • Java GUI cursor position in the window, mixed text editable and uneditable

    Hello,
    I primarily program in VBScript for Client Acces; but, I wanted to start creating user interfaces with Java.
    VBScript is not compiled on the private drive and anyone can learn how to do a program from well documented code; however, a compiled .class Java program does not have to be sent with the .java source code to work. The compiled program is unreadable by others and uneditable by others. Although I can do what I want with ActiveX programming, I want to use Java instead because it will prevent others from knowing how I program my solutions.
    The NetBeans IDE allows for controls to be dragged and dropped onto a screen; however, I want to know how to have uneditable and editable fields on the same page while allowing the cursor to be anywhere on the page and report its cursor position just as it is reported in Client Access.
    Does Java support the .Net Framework; or, does it have its own objects and methods to pull the cursor position in a window? I need the row and column, not the x and y coordinates.
    Java How To Program, Sixth Edition, has some deprecated code examples and I found working solutions from the Java Almanac. However, I did not see an example of this sort.
    What I will do once I know how to track the cursor position in the window is generate a Java based training module. Every computer at my workplace has Java runtimes installed, none of them have the .Net Framework installed. Java has a lot of tools that allow me to replace all my ActiveX programming with Java programming.
    Have a great Day!
    Jesse Grune.

    textArea.getCaret().getDot();
    or the shorter
    textArea.getCaretPosition();

  • [ADF Faces] set cursor position to the first column input text in ADF table

    How do i set the cursor position to the first column input text when i Insert a blank row?
    My idea is to implement using javascript. document.setfocus() but how do i do it from the backing bean code? or how do i install custom js to call document.setfocus()?
    any ideas?
    Message was edited by:
    user450391

    Did you try by iterating the selected row?
    Bind the table with the managed bean and then try with below code:
    RichTable empTable;
    RowKeySet selectedEmps = getEmpTable().getSelectedRowKeys();   
    Iterator selectedEmpIter = selectedEmps.iterator();
    DCBindingContainer bindings = (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
    DCIteratorBinding empIter = bindings.findIteratorBinding("EmpView1Iterator");
    RowSetIterator empRSIter = empIter.getRowSetIterator();
    while(selectedEmpIter.hasNext()){
       Key key = (Key)((List)selectedEmpIter.next()).get(0);
       Row currentRow = empRSIter.getRow(key);
       System.out.println(currentRow.getAttribute("Ename"));

  • Locating the cursor position

    Is it possible to locate the cursor position in a text item? in other words can I find the number of characters to the left of the cursor in a text item?
    I really appreciate any kind of input on this.
    null

    I have to insert user selected variables that show up in a LOV into the text item at the cursor position.
    A sloppy workaround for this problem is asking the user to put in a pre defined symbol where ever he/she wants to insert the variables and then replace the variable with the value selected from the LOV using the REPLACE function. There is always a chance of error here!
    Instead if there is a way to know the cursor position, like the no. of characters to the left of the cursor or the cursor co-ordinates.............

  • Can any body answer this-Want to set the cursor position in textfield.

    i want my cusor position in textfield at the initial position which will come by default.
    but when i'm using the textfields in an inner class i'm getting the cursor position at the end of the text in text filed.pls can any body answer this.
    thanks in advance.
    if want run this example.
    import java.awt.*;
    import java.awt.event.*;
    class Testing extends JFrame implements ActionListener
         Container cnt;
         JButton jd;
         JTextField jt1;
         JTextField jt2;
         Testing()
              cnt = getContentPane();
              cnt.setLayout(new FlowLayout());
              jd = new JButton("OK");
              //jd.setBounds(50,50,100,30);
              cnt.add(jd);
              jd.addActionListener(this);
         public void actionPerformed(ActionEvent ae)
              Object but = ae.getSource();
              System.out.println("in action 00000");
              if(but.equals(jd))
                   System.out.println("in action ");
                   call();
                   return;
         void call()
              System.out.println("in action 1111111111");
              Inner inn = new Inner();
              inn.jdlg.show();
         public static void main(String s[])
              JFrame jf = new Testing();
              jf.setSize(200,200);
              jf.show();
         class Inner
              JDialog jdlg;
              //JTextField jt1;
              //JTextField jt2;
              Container cnt;
              Inner()
                   jdlg = new JDialog();
                   JLabel jla = new JLabel("Label");
                   jt1 = new JTextField();
                   jt2 = new JTextField(5);
                   cnt = jdlg.getContentPane();
                   cnt.setLayout(new FlowLayout());
                   cnt.add(jt1);
                   cnt.add(jt2);
                   jt1.setText("aaaaaaaa");
                   jt2.setText("bbbbbbbb");
                   System.out.println("the text "+jt1.getText());
                   jdlg.setSize(200,200);

    JTextFiled.setCaretPosition(0);

  • How to control the cursor position on a text item..

    Hello,
    How can we control the cursor position programmatically on a text item.
    i.e. how do we move the cursor to home or end of the text item.
    TIA,
    Hiten

    If you have an access to metalink.oracle.com, take a look at notes:
    Note 61656.1 (V45) HIGHLIGHTING A REGION OF TEXT
    Note 131028.1 Default Highlighting in Forms (Client Server)
    and threads from metalink forum:
    531481.996 "Select_All not working in 6.0.8.25.2", 153092.995 "Text item cursor position"

  • How to set cursor at the first line in a table control?

    Hi,
           I have a customized infotype screen where a table control is being used to input new values.The tab control has 30 lines.Now, the problem is that when the screen is displayed, the cursor always starts at 8th or 4th line.The behaviour is not very consistent.I tried the following statement in the PBO, but no effect.
    SET CURSOR FIELD P9417-ZCOUNTRY LINE 1.  ( P9417-ZCOUNTRY is the name of the tab control field where i want to set the cursor ).This is the last statement in the PBO.
    Can someone please tell me why still I am not able to set the cursor at the first line? I have infact noticed that , in the debugging mode , sometimes the cursor starts at the first line.Please help. Thanks

    I have got a new requirement on this now. If the table control does not have any records , then the cursor position should be on the first row.Otherwise, if it already has some records, then the cursor should be at the first empty row.I wrote the code like below.
    if sy-ucomm = 'INSERT'.
    set cursor 'P9714-ZCOUNTRY'  line 1.
    else if sy-ucomm eq 'CHANGE'.
    describe table itab lines fill.
    fill = fill + 1.
    set cursor 'P9714-ZCOUNTRY'  line fill.
    endif.
    I am facing a strange problem now.The table control has some 10 rows when you see the screen for the first time.If the number of records already present is less than 10, I am able to position the cursor on the first empty row.But if the number is say 15, then the cursor position goes to eighth or fourth line or sometimes the first line.
    Is there any way to display the last few records , ie, if there are 15 records , is there any way to display the last five rows when I see the screen for the first time, rather than showing the first 10 records?How can I position the cursor at the first empty row, when there are more records?
    Thanks in advance..good answers will be rewarded.
    Mahesh

  • How to get the cursor position on a picture?

    I'd like to show the cursor position on a picture
    which is 400 by 400 pixel size and located at
    (0, 0, 400, 400) on a panel. So suppose that the
    cursor is at (50, 50), how can the java code know?
    Thank you.

    I am thinking about this, and use something like
    JPanel.setFocusable(true). Thank you.

  • Can I control the cursor position

    I'd like to confine the cursors position to a grid when it's within a particular panel. I tried public void mouseMoved(MouseEvent e)
    int x = (int) (GRIDSIZE*java.lang.Math.round(e.getX()/(1.0*GRIDSIZE)));
    int y = (int) (GRIDSIZE*java.lang.Math.round(e.getY()/(1.0*GRIDSIZE)));
    e.translatePoint(x,y);
    } But that didn't work. Can it be done?

    I'm not exactly sure what you want to be done, but, if you want to control the mouse position, you can create a Robot object (check the class in the java docs) and use robot.mouseMove(mouseX,mouseY) where mouseX and mouseY are integers. THIS ONLY WORKS IN APPLICATIONS THOUGH. its too powerful to be able to control a persons mouse, (and keyboard is controllable too with Robot), you can imageine what a person could do lol.. Anyway, you could repeatedly check if the mouse position is on the grid, and if it isn't, use robot.mouseMove, to place it onto the grid.

  • Controling the cursor position

    Hi all,
    I have two x, and y signal outputs from a dll module and I plan to use them to control the cursor position. One problem I'm facing is that my signals are variable enough to cause the cursor to vibrate in stationary setting. So, I use hysterysis (putting threshold) to eliminate these fluctuations but the drawback is that keeping the treshold high enough to eliminate the fluctuations keeps me from getting a nice, smooth movement when the speed of movement (rate of x and y changing) is low. Any ideas or suggestions will be appreciated.
    p.s. I am using "SetCursorPos".dll as you might have already guessed.
    Thank you,
    Elnaz

    The formula for an exponential filter of degree D is the following:
    New Average = (New Value + (D-1)*Old Average)/D
    I usually add a special case for startup so that D is never greater than the number of points. 
    As I said, it is a low-pass filter, much like using a running average.  I usually like it because the state is simply a single value (Old Average) instead of the array of values you have to keep around to do a running average.
    As to the new question of separating high-frequency noise from your high-frequency signal, that is a bit more complicated (obviously).  You should take a power spectrum of the noise to see if there is a characteristic feature you can use (cutoff frequency, strong peaks).

  • Photoshop CS5 - Control and navigate the cursor position automatically

    Hello
    I wonder if it’s possible with Photoshop CS5 (OS: Win7)  to control and navigate the cursor position automatically?
    Given: I have individual image coordinates for a set of locations.
    Wanted: A possibility to position the cursor sequentially at those image location by the means of an external script or procedure.
    Any ideas if that is possible with CS5?
    Thanks for any help.
    Lars

    As far as I can tell with regard to a Photoshop Scripting approach: No.
    Creating a Selection of certain dimensions and a certain position would be possible, though.
    What exactly are you trying to achieve?

  • How can I return to the same position in the calling order details form

    I am Calling a form for creating a new item from order details form, so after creating The new item I want to returned the item code to the calling form to same position in The order details form , how can I return to the same position in the order details form
    Waiting for your valuable answer .
    Best regards
    Jamil Alshaibani

    Dear Friends
    My actual problem description as the following
    I have a form for production order screen , and this form contain header and details blocks , so the user in the details will select Type Code , and he will go the next field that is Item Code Field search for specific Item Code if it is not exist he has to call the Item Definition Form by using this script
    CALL_FORM(ITEM_DEFINITION);
    Then when he finished defining the Item , and I assign the item code as the following in the :
    WHEN-BUTTON-PRESSED TRIGGER
    :GLOBAL.ITEM_CODE_VAR := :ITEM_CODE;
    DO_KEY('exit_form');
    But I don't know where to keep this assignment
    :ITEM_CODE := :GLOBAL.ITEM_CODE_VAR;
    inside the caller form in which trigger do I have to use when it return from the caller form it should assign the :GLOBAL.ITEM_CODE_VAR to the :ITEM_CODE and the cursor it should show inside the ITEM_CODE , and as I mention it does not return to the same location of The ITEM_CODE when it return from the calling form
    Waiting for your valuable answer .
    With example please .
    Best Regards
    Jamil Alshaibani

  • Position Cursor on GRAPH either by dragging it OR entering the dsired position in the Cursor legend

    I've written a VI that allows the user to import a dataset, view it on a graph, and then use cursors to "filter" the range of data that I'm interested in, by sending the cursor.index values from the first graph to an array subset function which feeds a second graph.  The problem is that I'd like to provide the user the ability to position the cursors on the first graph both visually - by dragging - (for "course" control) AND by entering the desired values directly into the cursor legend (for fine control).  The problem is that I cannot find a way to do this, since I have to have the Lock Ring set to “Lock to Plot” in order to capture the index information. According to the documentation, the only way to be able to position the cursors via the Cursor legend is to set the Lock Ring to “Free”, which means the index values are rendered useless, since the cursor is no longer locked to the plot.  If I leave the Lock Ring in "Lock to Plot", and enter a value in the cursor legend, it does move the cursor, but not to where it should.  If I enter a value an x value of 9.0 for cursor 1, the cursor goes to 10.2638.  The next time I enter 9.0, it goes to 9.82794.  I don't understand what the issue is.  Is there a way around this?
    Attachments:
    ppv data filter 3.vi ‏366 KB

    Yes Rudi:  What I want is for the operator to place the cursors by dragging them (just eye-balling it).  The, if they see that the Y cursor (horizontal) is at 10.234, and they want to make it 10, they could simply enter that value in the cursor legend, and the cursor would be placed exactly at 10.  The only way to do this seems to be to select the “Free” option for the cursor.  However, in order to use the first graph to set the boundaries of the second graph, I have to use the Cursor Index from the first as an input to the Array Subset that feeds the second graph.  In order to use the Cursor Index, the first graph has to have its cursor Lock Rings set to “Lock to Plot”.  Am I making this any more understandable, or just rambling?

Maybe you are looking for