Dear all,

My form panel has the following script format for all my columns:

    <textField name="CP_SHNM" tabIndex="110" column="CP_SHNM" dataSource="OTV_SO_M">
      <events>
        <focusGain action="FOCUSGAIN"/>
      </events>
    </textField>

I am using api_application.getfocusedcomponent in the FOCUSGAIN event. And I get the name of the component as OTV_SO_M.CP_SHNM. I get similar results for all my columns in the panel.

However, when I am in the grid I do not get this result for all my columns. I am using api_application.getfocusedcomponent('Y'). It gives me DATASOURCE.COLUMNNAME value for only for the first item I am focused for each row. However, if I change my focus to another column in the same row the FOCUSGAIN event is not triggered. My script is as follows:

    <grid name="OTV_SO_ITEMS_GRID" dataSource="OTV_SO_ITEMS">
      <events>
        <focusGain action="FOCUSGAIN"/>
      </events>
      <column name="SRNO@LAB" headerLabel="Srno" width="33">
        <textField name="SRNO" column="SRNO"/>
      </column>
      <column name="TENDER@LAB" headerLabel="T" width="17">
        <textField name="TENDER" column="TENDER"/>
      </column>

Kindly help me find the name of the focusedcomponent for each column in the grid.

George.

asked 28 Nov '13, 09:53

grajan777's gravatar image

grajan777
1011229
accept rate: 10%


Hi George,

To accomplish your request, you should define a focusGain event for each component existing in your grid:

<grid name="OTV_SO_ITEMS_GRID" dataSource="OTV_SO_ITEMS">
  <column name="SRNO@LAB" headerLabel="Srno" width="33">
    <textField name="SRNO" column="SRNO">
      <events>
        <focusGain action="FOCUSGAIN"/>
      </events>
    </textField>
  </column>
  <column name="TENDER@LAB" headerLabel="T" width="17">
    <textField name="TENDER" column="TENDER">
      <events>
        <focusGain action="FOCUSGAIN"/>
      </events>
    </textField>
  </column>
</grid>

Regards, Ibrahim

link

answered 28 Nov '13, 16:17

Ibrahim%20Sandalli's gravatar image

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

Hi Ibrahim,

Thank you. I will try this.

George.

(28 Nov '13, 17:10) grajan777
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:

×1

Asked: 28 Nov '13, 09:53

Seen: 539 times

Last updated: 28 Nov '13, 17:10

Related questions


© Copyright Gerger 2017