home *** CD-ROM | disk | FTP | other *** search
- GRID.TXT
- "Explaination of the Grid Control"
- by Jonathan Zuck
- User Friendly, Inc.
-
- What I have tried to do here is to document the various properties
- of the Grid control (including a couple I added), for those who do not
- read C. I am going on the assumption that the properties that appear
- in the VB editor are self-evident. Be sure to let me know if that is
- a flawed assumption. Accordingly, I will be documenting the run-time
- properties only.
-
-
- The following two properties can be retrieved or set to determine or set
- the cell in the grid that currently owns focus. You must change these
- settings in order for the TEXT, ROWHEIGHT, COLWIDTH, COLALIGNMENT properties
- to have meaning. Each of these operates on the cell that currently owns
- focus.
-
- ROW (Int)
- The Row of the Cell that has focus
- This can be both retrieved and set at run-time.
-
- COL (Int)
- The Column of the Cell that has focus
- This can be both retrieved and set at run-time.
-
- TEXT (String)
- The contents of the current cell.
- This can be both retrieved and set at run-time.
-
- ROWHEIGHT (LONG)
- The hight of the row containing the current cell
- This can be both retrieved and set at run-time.
-
- COLWIDTH (LONG)
- The width of the row containing the current cell
- This can be both retrieved and set at run-time.
-
- COLALIGNMENT (Int)
- The column alignment of the column of the current cell
- This can be both retrieved and set at run-time.
-
- CELLSELECTED (BOOL)
- Returns TRUE/FALSE if any cells are/are not currently selected.
- Read-only at run-time
-
- SELSTARTROW (Int)
- The starting row of the selection block
- This can be both retrieved and set at run-time.
-
- SELENDROW (Int)
- The ending row of the selection block
- This can be both retrieved and set at run-time.
-
- SELSTARTCOL (Int)
- The starting column of the selection block
- This can be both retrieved and set at run-time.
-
- SELENDCOL (Int)
- The ending column of the selection block
- This can be both retrieved and set at run-time.
-
- CLIP (String)
- The currently select text (tab and CR/LF delimited)
- This can be both retrieved and set at run-time.
- Note: This property can be used to retrieve and save delimited
- text files or perform advise links with EXCEL.
-
- TOPROW (Int) (I added this)
- The Top most visible row in the grid.
- This can be both retrieved and set at run-time.
-
- LEFTCOL (Int) (I added this)
- The Left most visible column in the grid
- This can be both retrieved and set at run-time.
-
- Note: I added the above two properties because there was no way to
- programatically scroll the grid. Using these properties, you can force
- a particular cell (or just a row or column) to be the visible origin of
- the grid. The top row and left column are contrained by the the number
- of fixed rows and columns and the number of remaining rows and columns.
- Therefore, you cannot use this to set new titles or to bring the last
- row/column to the origin.
-
- Hope this helps!
- JZ
-