CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 1999
    Posts
    3

    grid control scroll

    Hi!

    Im having a problem with grid control.

    When i try to change value of grid1.leftcol property, it doesnt change at all.

    Why doesnt it change?

    Grid1.leftcol is used to set leftest column number in grid control. (Is there
    other way of doing this?)

    I am using visual basic 6.0.

    Newbie


  2. #2
    Join Date
    May 2001
    Location
    Canada
    Posts
    182

    Re: grid control scroll

    How about Grid1.FixedCols ?

    Regards,

    Michi

  3. #3
    Join Date
    Apr 1999
    Posts
    3

    Re: grid control scroll

    grid1.fixedcols is the number of header columns in a grid. It doesnt
    change the leftest column index at all.

    Newbie


  4. #4
    Join Date
    May 2001
    Location
    Canada
    Posts
    182

    Re: grid control scroll

    I tested the LeftCol property of MSFlexGrid just now, it works fine for me. Would you please show your codes up?

    Regards,

    Michi

  5. #5
    Join Date
    Apr 1999
    Posts
    3

    Re: grid control scroll

    There is just a horizontal scroll and it should set new values to grids if
    hscroll is moved.

    grid1 and grid3 is MSFlexGrid and grid2 is MSHFlexGrid. These are both on version 6.0.

    And the problem was that leftcols doesnt set to any value.

    Code:

    Public Sub HScroll1_Change()

    Grid1.LeftCol = HScroll1.Value
    Grid2.LeftCol = HScroll1.Value
    Grid3.LeftCol = HScroll1.Value

    End Sub

    Grid1:

    Begin MSFlexGridLib.MSFlexGrid Grid1
    Height = 855
    Left = 120
    TabIndex = 17
    TabStop = 0 'False
    Top = 720
    Width = 5655
    _ExtentX = 9975
    _ExtentY = 1508
    _Version = 393216
    Rows = 3
    Cols = 21
    FixedRows = 0
    BackColorFixed = 12632256
    ScrollTrack = -1 'True
    Enabled = -1 'True
    ScrollBars = 0
    End

    Grid2:

    Begin MSFlexGridLib.MSFlexGrid Grid2
    Height = 2775
    Left = 120
    TabIndex = 50
    Top = 1560
    Width = 5895
    _ExtentX = 10398
    _ExtentY = 4895
    _Version = 393216
    Rows = 250
    Cols = 21
    FixedRows = 0
    BackColorFixed = 12632256
    ScrollBars = 2
    End


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

Featured