Hi formspider team,

api_application.getfocusedcomponent is a feature I was eagerly looking for in 1.3.0. Though the change log says that it is fixed it is still not working. I am getting the following result. The command given in a key event is:

api_application.showpopupmessage(api_application.getfocusedcomponent);

My grid panel name is: TEST_GRID the result displayed is: TEST_GRID

My test script is as under:

    <grid dataSource="TEST_GRID" >
      <column nameheaderLabel="Cost Center">
        <textField name="CP_SHID" tooltip="Cost Center" column="CP_SHID"/>
      </column>
    </grid>

George

asked 10 Apr '13, 06:29

George's gravatar image

George
1111226
accept rate: 0%


Hi George,

I guess you are expecting CP_SHID as the result. In 1.3.0, a new parameter named in_innerComponent_yn is added to the api_application.getfocusedcomponent API, having 'N' as default value. When the focus is in a component existing in a grid component; if the value of the in_innerComponent_yn parameter is equal to 'N', this API returns the name of the grid component, as in your case. However, if its value is equal to 'Y', it returns the name of the focused component inside of the grid. Therefore, you can use the API by setting 'Y' as in_innerComponent_yn parameter to retrieve the name of the focused component in the grid:

api_application.showpopupmessage(api_application.getfocusedcomponent('Y'));

Hope this helps,
Ibrahim

link

answered 10 Apr '13, 07:44

Ibrahim%20Sandalli's gravatar image

Ibrahim Sand... ♦♦
1.5k5
accept rate: 25%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×85
×4

Asked: 10 Apr '13, 06:29

Seen: 980 times

Last updated: 10 Apr '13, 07:44


© Copyright Gerger 2017