on 02-21-2006 6:52 AM
Hi,
I am trying to set the focus in a table to a new row which I have created(Always created at the end). Im using the following line :
allocationnode.addElement(allocationele);
allocationnode.moveLast();
But its not working. A new row is getting created. But the focus doesnt change
I also tried:
allocationnode.setLeadSelection(size-1);
But in vain.
Can anyone tell me what the problem could be?
Thanks in Advance,
Reena
Reena,
Write this code after you add the element to the table.
int i = allocationnode.size() - 1;
allocationnode.setLeadSelection(i);
This will highlight the lastly added row in the table if the selection mode in the table is "auto".
Bala
Message was edited by: Bala Krishnan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Valery,
"If row is not highlighted, then it is one problem...... "
I am not able to identify if a row is higlighted or not.
The table in my application currently has 20 rows, of which only 5 are visible ( I have set visibleRowCount = 5 ). The selectMode of my table is 'None'. ( I donot want to use 'Auto' ).
Now, I have called an action on the click of a button, in order to insert an empty row into the table and I have written the code to add and move in this method.
When I click the button, I see the number of rows changing from 20 to 21. But the table still shows the first five rows. I want the focus to shift to the last row.
Thanks in Advance,
Reena
Try method IWDViewController.requestFocus(IWDNodeElement, IWDAttributeInfo)
Pass the node element corresponding to the new table row and the attribute (info) shown in the table column.
Armin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.