How do I set focus to a text field after I click a button that calls a webservice?

I have a web service that returns back a table. In order to show the values in the table I had to check the re-merge Form Data on the Webservice Button.  My question is , How do I set focus to a field on the screen after re-merge happens.

I was reading SetFocus documentation and it says
You cannot use  setFocus with the form:ready, layout:ready, or initialize events.
What I need is an event like doc:ready or someother event where I can put the set focus code in. doc:ready was triggered when the form first loads which is great and I was able to put my Initial setfocus. When I pressed the button that calls the webservice and thr re-merge happened doc:ready event was not triggered so now I am not sure where to put the set focus.

Similar Messages

  • Cursor not focusing in the text field after Object tag load in IE

    Hi,
    We have an applets class "ABC.class" in our application. To include this class in a jsp page we are using OBJECT tag. This tag is written inside a if block in the jsp page. Based on the if condition this OBJECT tag has to be loaded. Below is the code we are using:
    <%
    if(testCondition)
    %>
    <OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" NAME="applet" width="0" height="0">
    <PARAM NAME="CODE" VALUE="ABC.class" >
    <input type="hidden" id='myText' value="Please configure the jinitiator version to Oracle applicaitons Jinitiator version." >
    No JDK 1.3 support for APPLET!!
    </OBJECT>
    <%
    %>
    In the above code if the "if condition" is satisfying, then cursor is not focusing on the required field. The code to focus on the field is written in the javascript function which is called onLoading the page.
    we are using IE 7 and IE8. In IE 7 sometimes working fine but in IE 8 we are getting this issue.
    Can anyone please help us how to focus the cursor on the required field even in the case of the Object tag loading.
    Thanks,
    Eswari

    Hi Nicky,
    Thanks for your reply.
    We are not using JQuery.
    Actually the code to focus is written in the function which is called onLoad of the page that will be executed after the page loading. If we keep alerts in the onLoad function then the cursor is focusing to the required field.
    Thanks,
    Eshwari

  • Unable to set focus to login text field AUTOMATICALLY on page load

    Hi,
    I'm trying to have my flash (AS 2) login page have the
    username field start blinking right away after the page is loaded
    but so far, no success.
    I've added the following Javascript to the HTML wrapper:
    But it still doesnt work. Can anyone help?
    See whats happening by
    clicking here.

    Use the following in the Flash code:
    Selection.setFocus(username_field_instance_name);

  • How to set focus on a input field in a selected row of a table?

    In a previous discussion (http://scn.sap.com/thread/3564789) I asked how to access an input (sap.m.Input) field of a selected row in a table. In the answer that was supplied I was shown how to get the items of the table. Then using the selected index to get the selected item get the cells. Then I could set editable on the proper cell(s). This worked fine.
    Now I need to set the focus on one of the fields. I tried something like this:
                var oNewLink = table.getSelectedItem();
                var oNewLinkName = oNewLink.getCells()[1];
                oNewLinkName.focus();
    But this doesn't seem to work.
    I have searched through other discussions and have seen this technique for putting focus on a field if you have its ID:
    sap.ui.getCore().byId(id_of_the_input_field).$().focus();
    In my case though I do not have an ID since the row and its cells are generated. How can I set focus on the cell of a certain row in a table?

    Hello Venkatesh. Yes that code does work. First I tried it on a table cell that was already rendered and it did work. The next time I tried it on a table row that was being added and it did not work there. So I added an on after rendering function for the table and added that code there. That did not work until I added a delay (timeout) to do a context switch before calling the focus and that worked.
    Once last thing though sometimes when I call focus on an input field (actually in a table row cell) if the field has text in it already the flashing cursor is at the beginning of the text and other times it is at the end of the text (which is the desired way). It depends on where I click in the row. Is there anyway to make sure the flashing cursor is at the end of the text when the focus is applied to a field that contains text?

  • How Can I Set a Default Placeholder Text Language?

    How can I set a default placeholder text language instead of having to set the language every time I use placeholder text?

    Steve Werner wrote:
    I think the default placeholder text language is the language of your version of InDesign.
    The placeholder text is based on the current language setting. So if the language under the cursor is Hebrew, you'll get Hebrew.

  • How do I set up a group text

    How do I set up a group text from my contacts with my droid maxx?Kathleen

    Hey zzmama294,
    Thanks for the question. I understand that wish to learn more about group messaging. The following resources may provide assist you:
    iOS: Understanding group messaging
    http://support.apple.com/kb/HT5760
    Send a message to a group - Message - iPhone Basics
    http://support.apple.com/kb/TI82
    Thanks,
    Matt M.

  • HT3529 How do I set a signature for text messages?

    How do I set a signature for text messages?

    You can set a signature in Mail but not in Messages.

  • How to set focus on invisible input field?

    Hi Guys,
    I need an invisible input field and have to set an input focus on it. My problem is that if I set input field’s property visible=blank, I get my invisible field <b>BUT</b> the function call doesn’t work (setInput.requestFocus()).
    I suppose that I can’t set a focus if an input field is invisible.
    Does somebody know how can I solve my problem? Is there a possibility to do this input field invisible with java script? If yes, how does it work in Web Dynpro?
    Thanks
    Marita

    Hi
      Setting a focus on invisible input field will not work even if you follow the method what sowjanya has suggested. The method wdThis.wdGetAPI().requestFocus() will not work for read-only and disabled fields.
    By the way why do you want to set the focus on a invisible input field. If you can tell us the requirement maybe we could think of an alternate solution. But i guess for the current scenario setting focus on invisible input field does not work.
    regards
    ravi

  • Setting the focus to a text field on a subform in the form initialize event.

    I have a form that checks the rawValue of a text field to determine whether or not the focus should be set on a particular text field. Here is the logic:
    if(txtEmailVisible.rawValue == "visible")
    frmEmailData.presence = "visible";
    xfa.host.setFocus(xfa.form.NEDA.main.frmEmailData.txtEmailBody);
    else
    frmEmailData.presence = "hidden";
    For some reason the focus isn't going to that object, instead it is still going to the first field in the tabbing order. Am I calling this in the wrong event, which is causing the tabbing order to over ride my setFocus call?
    Thanks,
    Chad

    Try using setTimeout for this from the DocReady event.
    app.setTimeout("xfa.host.setFocus(xfa.form.NEDA.main.frmEmailData.txtEmailBody);
    ", 250);
    There are several occasions where code must be executed after init/formReady/DocReady, etc. has been completed. This is one of them.

  • How to set focus on an input field by coding?

    Dear friends,
    Do you have such experience if we can set focus on an input field by code?
    Thanks and best regards,
    Anders

    Hi,
    There are two ways to set the focus of an inputfield.
    1) In the BSP page add the attribute focus to an inputfield and set it to true.
    Ex: <thtmlb:inputField id = "test"
                          focus = "TRUE"/>
    2) Using the P-getter in the case where the inputfield is created using the config tool.
    Ex: CASE iv_property.
    WHEN if_bsp_wd_model_setter_getter=>fp_focus.
    rv_value = abap_true.
    ENDCASE.
    regards,
    MuralidharPrasad.C

  • How to make the focus to the TextInput field

    Hi,
            How to make the focus to the TextInput field. I tried with userIDTxtIt.setFocus();  The focus is available to the text input. but when i enter the value as 'Thiru' to the TextInput field, the keyboard is not available there. so i tried with userIDTxtIt.dispatchEvent(new MouseEvent(MouseEvent.DOUBLE_CLICK));
    still key board focus is not availble to the text input.
    Regards,
    Thiru

    Thanks for your reply.
       I got the more info by reading the comments inthe following link.
    http://blog.flexexamples.com/2008/09/23/setting-focus-in-flex-using-the-focus-manager/
    regards,
    Thiru

  • How to move the cursor to a text field

    Hello,
    I have a log in window with Username (Text field) and password (Secure Text field). The 'Log In' button is not enabled if I use the Set command. So I wish to use the Keystroke.
    But I need to make sure that Cursor is in the text field and then to keystroke. So how can I move the cursor to the required text filed?
    Note:
    +Why the cursor is not blinking in the text field where I just 'SET' (command)+
    +the value?+

    Well, for a start you can identify the application you're working in. That's kind of important.
    In most cases you can just emulate a press of the tab key but it's kind of a crude a approach (there's no guarantee that you're in the field you expect). Certain applications, though, may have better ways of achieving it, but since we don't know what application you're using we can't say if that's the case here.

  • How to make ? nr of container text fields

    hi have this fla wich has 2 sets of containing text fields
    after a php file gets the only two rows in a database, it puts the values in the textfields.
    now what i want is
    i want flash to put the instances of the textfields automatic on the stage
    like when there are 8 rows, i want 8 sets of textcontainers.
    how do i do thiss.
    i have this really simpel fla file
    wich can be downloaded here
    http://www.flash-db.com/Tutorials/loadingAS3/loadingAS3_flash-db.rar
    its in the BD folder, also the php file
    would be so nice if someone could edit the fla file, so i can check out how this is done?
    or maybe a tutorial on this or something?
    thx so much in advance

    Hi Allice,
    You can use this :-
    for ( var i=0;i<8;i++)
    var txt:TextField=new TextField();
    txt.name="txt"+i
    txt.x = 0
    txt.y=i*10
    addChild(txt)

  • Updated - Cursor focus in HTML text field in JEditorPane

    The last poster just save my bacon - so an update for others: Adding a JEditorPane to a JWindow will result in all the <INPUT type=text> form elements to be non focusable. Switching to JFrame does make things work again - but I would love to have a JWindow again (I don't want the title bar for a kiosk type operation).
    thanks!
    brian
    Here is the guy I do thank!!!
    ** PROBLEM
    How do I make cursor focus go into an HTML text field in a JEditorPane?
    My test appplication is a JPanel containing a JEditorPane and nothing else. The content type is text/html. The HTML text contains a form and an INPUT TYPE=TEXT tag. I use setEditable(false) because I do not want the user to edit the paragraph text, only to type in the text field.
    The text field does not get cursor focus. Tab does nothing. The user can click with the mouse to place focus in the text field, so the field is capable of receiving focus. I guess the field is in a View that stops it participating in the component hierarchy.
    Is there a way to make this work?
    ** SOLUTION! - ok, if you don't use JWindow
    It turns out that setEditable(false) is not enough. The JEditorPane still gets in the way of the focus cycle. It also needs setFocusCycleRoot(false) and setFocusable(false) to prevent it from participating in focus. Focus on the text field then works normally.
    fp

    I don't want the title bar for a kiosk type operation).You could use an undecorated frame. Read the API for more info.
    Or, maybe this posting will help:
    http://forum.java.sun.com/thread.jspa?forumID=57&threadID=675445

  • How can I set my phone to delete messages after a certain period of time? 6 months, 1 year??? It is taking up over 4GB on my phone.  I don't want to delete everything just the oldest ones.

    How can I set my phone to delete messages after a certain period of time? 6 months, 1 year??? It is taking up over 4GB on my phone.  I don't want to delete everything just the oldest ones.

    If you update to iOS 8, you can select that in Settings>Messages>Keep Message and then select your option. If you don't update to iOS 8, you'll need to do it manually.

Maybe you are looking for

  • My InDesign CC will not open the first time I attempt to open files.

    Hello, Does anyone else have issues with InDesign not opening on the first attempt? I am on a Windows 7 op system. Once I close the program and reopen it, it usually works...the 2nd time. Any help appreciated. Thank You, Jason

  • How to check if my apple care covers hardware damage

    My Macbook pro is under apple care . but i don't know if it covers hardware damage. How can i check it.

  • Why the Docentry and DocNum for Outgoing payment is same?

    Hi, I have define the numbering series for Outgoing payment , But while i created the outgoing payment document, in the backend the docentry and docnum values are same. Anyone have idea why its happened? i am using 2007 B Regards, Senthil Kumar

  • Multiple database instances

    Dear Team, Please let us know what are challenges involved in having muliple instances on Production database server with data guard setup. if there are any performance gain/impact. managibility Thanks, AJ

  • Ship to party search help address not display

    Hi, Using 'Edit internal address' We added one plant address, and the address no also generated. plant having several address. But when we creating shopping cart, trying to select the ship to address from the search help, address not displaying in th