Subject AW: Current record lost on sorting by a column in TIB_Grid
Author Thomas Lenders
I found out that the property "AutoFetchAll" was FALSE leading to the kind of erratic jumping around of the current record. I am still thinking about wether this makes sense or not.

Oh, and I understand the difference between "KeepDataPos" and "KeepRowNumber" now so no need to explain that anymore. :)

Regards,
Thomas

Von: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] Im Auftrag von Thomas Lenders
Gesendet: Di, 18. Juni 2013 10:31
An: IBObjects@yahoogroups.com
Betreff: [IBO] AW: Current record lost on sorting by a column in TIB_Grid



Well,

the RefreshAction is set to "KeepDataPosOrRowNum" .. which setting is actually the correct one if I want to keep the current record selected after ordering? I think there must be another problem too because at this point I actually tried every one of these setting multiple times. ;)

I can reproduce the problem in a minimal application with one of TIB_Connection, TIB_Query, TIB_DataSource and TIB_Grid. Connect them all and and enter a simple SQL, e.g. select a few fields from a single table, including the primary key. Then I enter the name (including tablename like CUSTOMER.CUSTOMERID) of the PK into the "KeyLinks" property and disable "KeyLinksAutoDefine". Then I go to Ordering and add all fields there using the wizard.

All other settings have their default values.

When I run the application and click on the header of any column, the selected record changes.

Regards,
Thomas

Von: IBObjects@yahoogroups.com<mailto:IBObjects%40yahoogroups.com> [mailto:IBObjects@yahoogroups.com<mailto:IBObjects%40yahoogroups.com>] Im Auftrag von Svein Erling Tysvær
Gesendet: Di, 18. Juni 2013 08:32
An: IBObjects@yahoogroups.com<mailto:IBObjects%40yahoogroups.com>
Betreff: [IBO] RE: Current record lost on sorting by a column in TIB_Grid

Check your KeyLinks and RefreshAction, if KeyLinks isn't set (or incorrectly set), then IBO doesn't know how to distinguish the rows from each other and cannot relocate, RefreshAction you can set to e.g. keep the data position or the row number (though that probably also requires KeyLinks to be correctly set).

HTH,
Set

-----Original Message-----
From: IBObjects@yahoogroups.com<mailto:IBObjects%40yahoogroups.com><mailto:IBObjects%40yahoogroups.com> [mailto:IBObjects@yahoogroups.com<mailto:IBObjects%40yahoogroups.com><mailto:IBObjects%40yahoogroups.com>] On Behalf Of Thomas Lenders
Sent: 17. juni 2013 18:03
To: IBObjects@yahoogroups.com<mailto:IBObjects%40yahoogroups.com><mailto:IBObjects%40yahoogroups.com>
Subject: [IBO] Current record lost on sorting by a column in TIB_Grid

Hello group,

Something I did in an application using IBO 4.9.14 Build 55 caused a strange "feature", which is that when clicking on a column header to sort by that col, the current row changes.
Or, it could be something that changed between IBO version as switched to the version above after receiving a patch by Jason (it was easier to implement it in a more current version).

Anyone has an idea on the top of their head what could cause this behaviour ?

Regards,
Thomas

[Non-text portions of this message have been removed]



[Non-text portions of this message have been removed]