Results 1 to 3 of 3

Thread: VB: working with 2 grids

  1. #1

    Thread Starter
    New Member
    Join Date
    Dec 2008
    Posts
    2

    VB: working with 2 grids

    Friends, I have a new mission, in the theory seems easy, but I dont get..
    I am Using VB6, but I pretend to use .NET in the soon future.
    The situation follows:

    I have a forms with two GRIDs, of the same size, I need when I roll a ScrollBar at the one GRID, the another GRID must rolls too.

    I need to have ONE ScrollBar to move TWO GRIDs! is There a way?

    I use de index code from the selected Grid to select the index to another GRID.

    Thank you!

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: VB: working with 2 grids

    Welcome to the forums.

    This is a pure guess on my part. I don't use Grids so I really don't have anything to test it on, but if I were going to try this, I would do something like
    Code:
    Private Sub MSHFlexGrid1_Scroll()
    MSHFlexGrid2.TopRow = MSHFlexGrid1.TopRow
    End Sub
    
    Private Sub MSHFlexGrid2_Scroll()
    MSHFlexGrid1.TopRow = MSHFlexGrid2.TopRow
    End Sub

  3. #3

    Thread Starter
    New Member
    Join Date
    Dec 2008
    Posts
    2

    Re: VB: working with 2 grids

    First , thank you, for Help and Welcomesssss

    My Grid have not this property TopRow, because I use another Grid, is it right?
    What version of VB and what grid do you use ? I dont know the MSFlexGrid.;

    But I can do of the follow way:
    Code:
    grid1.FirstDisplayedScrollingRowIndex = grid2.FirstDisplayedScrollingRowIndex
    For sure I implement this of the another way, but...resolved!

    Thankyou´s
    Last edited by terra.jr; Dec 18th, 2008 at 03:18 PM.

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