Results 1 to 2 of 2

Thread: FlexGrid - ctrl select ?

  1. #1

    Thread Starter
    Addicted Member J@ck's Avatar
    Join Date
    Aug 2001
    Location
    London
    Posts
    179

    FlexGrid - ctrl select ?

    Wotcha, folks.

    When using the FlexGrid, is it possible to select multiple individual cells using the Control key and mouse button?

    I know Shift - Select works, but Control - Select doens't seem to.

    Am I missing something?

    Much ta.

    Jack.

  2. #2
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: FlexGrid - ctrl select ?

    No. The Flexgrid does not support the "extended selection" mode like other controls. It should be easy enough to code that functionality and in fact has been done before...

    From an old post -


    Turn off the automatic highlighting of the flexgrid by setting the Highlight property to flexHighlightNever. Then use this code in the click event.

    VB Code:
    1. Private Sub MSFlexGrid1_Click()
    2.     With MSFlexGrid1
    3.         .Row = .MouseRow
    4.         .Col = .MouseCol
    5.         If .CellBackColor = vbCyan Then
    6.             .CellBackColor = vbWhite
    7.         Else
    8.             .CellBackColor = vbCyan
    9.         End If
    10.     End With
    11. End Sub
    Last edited by brucevde; Apr 25th, 2005 at 10:29 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width