NewObject()

SelectOnEntry

This property determines whether the text in a grid column, text box or edit box gets highlighted when the user uses the keyboard to move into the control.

Usage

oObject.SelectOnEntry = lHighlightIt lHighlightIt = oObject.SelectOnEntry
The docs don't make it clear that SelectOnEntry is relevant only when the user tabs into a control, not when the user clicks into the control. In fact, clicking into an item has never highlighted it in FoxPro. (Double- or triple-clicking does let you select all, however.)

In a grid, SelectOnEntry only matters, of course, if the control in the cell is one that contains text. If there's no text to select, it's ignored.

In addition, there's interaction between the grid's Highlight property and the individual columns' SelectOnEntry. When Highlight is .F., SelectOnEntry is ignored and no text is highlighted on entry to a cell.

For text boxes and edit boxes, setting SelectOnEntry is a more readable alternative to using K in the Format property, which is no doubt why they acquired this property in VFP 5.

Example

ThisForm.grdMyGrid.colThree.SelectOnEntry = .F.

See Also

Column, EditBox, Format, Grid, Highlight, TextBox


View Updates

Copyright © 2002 by Tamar E. Granor, Ted Roche, Doug Hennig, and Della Martin. All Rights Reserved.



Hacker's Guide to Visual FoxPro 7. 0
Hackers Guide to Visual FoxPro 7.0
ISBN: 1930919220
EAN: 2147483647
Year: 2001
Pages: 899

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net