Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ActiveRow
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00148665
Message ID:
00148816
Vues:
18
>Hi,
>
>Just want to know why ActiveRow doesn't return proper row number ( always 0 ) if you put the codes outside of a grid?
>
>Example. Object: Command1 Procedure: Click
>
>ThisForm.Grid1.ActivateCell( 3,1 ) && Row = 3 & Column = 1
>ThisForm.Grid1.ActiveRow
>
>Row should return 3, but instead it return 0
>
>But if I put the same code in the Click event of the textbox of Grid1 column. It works fine because the row is highlighted and it has a focus..
>
>Setting the focus on the text of a grid column doesn't solve this problem if you have multiple rows . Is there are an alternative way?

Not disagreeing with what others have said, but here's another perspective: I have a case where I need to "remember" the exact cell between sessions as well as within a session. The tables and views are small in this case, so I simply write the current row/col to a table in afterrowcolchange when in grid, and restore cell with activatecell() using table values on page/form entry.

You can do similar with custom properties, if tables are small...
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform