Scrolling issues

Posted by: loy-chan on 8 September 2017, 1:44 pm EST

  • Posted 8 September 2017, 1:44 pm EST


    I'm experiencing a couple odd behaviours and I think it has something to do with the scrollbars. Note that I'm using the latest release. I'm unsure if this behaviour was present prior to this latest release.

    First off, my application consists of 1 spread control with 4 sheets. The first sheet consists of ~250 columns with frozen columns as well as some hidden columns. The other sheets are similar in composition but not as many columns.

    1st problem

    The horizontal scroll bar does not scroll to the absolute far right end. For some reason, it scrolls to about an inch from the end and just won't scroll any further. At this position, the right most column is visible. I can click on the scrollbar between the scroll position and the right arrow keys but it does not scroll to the end. What's odd is that all the horizontal scroll bar on the 4 sheets show the same behaviour.


    2nd problem

    I have a "view" in which i hide a good portion of the columns. In this view, if I try to click on a cell that is somewhere in right side of the spread then the spread will automatically scroll to the left. It looks to me like the spread is trying to make sure that active cell is visible or something. I did capture a left change event and it's trying to move from 158 to 142 (16 columns). My guess is that there some calculation on scroll position or something that is messed up. I think that this problem might be related to problem #1. In addtion, if i switch back to my full view (that doesn't hide any columns), this scrolling behaviour doesn't occur.


    I've tried to create a sample program to display this behaviour but I've been unsuccessful so far to recreate this behaviour. So in the meantime, could you suggest areas that I can focus my investigation? As wild guesses would be appreciated.



  • Replied 8 September 2017, 1:44 pm EST

    Great - thanks!
  • Replied 8 September 2017, 1:44 pm EST


    1) This may be expected behavior. The posistion of the thumbar in the scrollbar is based on the left most column index as a percentage of the total columns. So let's say you have 100 columns with 10 being able to be seen at one time and you have the last 50 columns hidden. If you scrolled to the right, the thumbbar would only go about halfway, since there is still 50 more columns to the right of the current location. Even though the columns are hidden is of no relevance to this calculation. We do not scroll a per pixel interval, but rather a per column interval.

    2) This is an already reported bug in the current release that will be fixed in the next maintenance release.

  • Replied 8 September 2017, 1:44 pm EST

    What is the solution for Problem1 ?

    When is the solution for Problem2 coming?

  • Replied 8 September 2017, 1:44 pm EST


    1) I answered this question in a seperate post that it is expected behavior and you would need to show the last column/row in order to see the scrollbar go all the way to the end.

    2) This is a bug that will be fixed in the next maintenance release. This is scheduld to release the end of March.

  • Replied 8 September 2017, 1:44 pm EST


    I believe issue 1 appeared during the last update as the scrolling problem is not apparent (for me anyway) in the previous (.3508) release regardless of hidden or shown columns.  Once I move up to the latest release, the scrolling doesn't work as it has previously. 

  • Replied 8 September 2017, 1:44 pm EST


    This issue will be fixed in the next maintenance release.

  • Replied 8 September 2017, 1:44 pm EST


    This may be a similar issue.

    I am in encountering problems relating to the use of the keyboard and scrolling within the latest versions of the Farpoint Spread control. The problem can be replicated using the code at the bottom of this message which sets up a simple sheet and then hides a block of rows and a block of columns. In order to replicate the problem it is important that the sheet dimensions and hidden blocks are the not changed.

    When using the cursor keys (up down left and right) the focus rectangle will disappear off the right or the bottom of the sheet without scrolling it.  In this situation the ShowActiveCell command will not bring the focus rectangle back into view.  Once you set all rows and columns as being visible then navigation of the sheet reverts back to normal and also ShowActiveCell works normally.  It would seem that for some reason the sheet 'thinks' is that the focus rectangle is in view when in fact it is not.

    This issue affects the following versions of spread:

    If I revert back to using version 03.00.2009 then there is no problem in this regard so it would seem that the problem applies only to the latest updates that you have released. I understand from your forum that you are planning further updates at the end of March and wanted to be sure that you are aware of this problem. Our application depends highly on hidden rows and columns and the use of ShowActiveCell.

    Is it possible to obtain an earlier version of Spread 4 (presumably versions 04.00.2008 or 04.00.3508) to use in the meantime as we would like to get on with development around the new PDF tool which of course is only implemented in Version 4?


    Code follows


    Imports FarPoint.Win.Spread

    Public Class Form1

    Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

    Me.FpSpread1.Top = 0
    Me.FpSpread1.Left = 0
    Me.FpSpread1.Width = 500
    Me.FpSpread1.Height = 500
    Me.FpSpread1.ActiveSheet.RowCount = 60
    Me.FpSpread1.ActiveSheet.ColumnCount = 30
    Me.FpSpread1.ActiveSheet.Rows(10, 30).Visible = False
    Me.FpSpread1.ActiveSheet.Columns(5, 20).Visible = False

    End Sub

    Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click

    Me.FpSpread1.ShowActiveCell(VerticalPosition.Nearest, HorizontalPosition.Nearest)

    End Sub

    End Class


  • Replied 8 September 2017, 1:44 pm EST


    This particular issue will be fixed in the next maintenance release. You can go to our ftp server to download previous version of Spread for Windows Forms 4, but I would highly suggest waiting for the next maintenance release if possible, since we are close to this release date.

  • Replied 8 September 2017, 1:44 pm EST


    I know that you will fixed this particular issue. So, When I download next maintenance release version!? and what's the version?


    Thank for your help.


  • Replied 8 September 2017, 1:44 pm EST


    By Monday we should be posting version 4.0.xx10 which will fix this issue.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels