Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
390
Unexpected bahaviour from grid
posted

I'm experiencing strange behaviour at runtime which I believe is inconsistent with design time. First picture shows design time view which is how I would like it to appear (almost anyway; last column needs to be extended to fill). The second picture shows runtime view. Initially there is a splitter bar across the top and the area below has no vertical scroll bar. I have dragged the splitter down revealing the same data with a vertical scroll bar. I only want to see the top area; not the lower area. Are these row scroll regions? If so, I've set it to 1 to try to prevent extra areas from appearing but why no scroll bar. I'm new to using the grid so any help appreciated. 

Thanks,

Craig

Design time:

 

 Run time:

  • 390
    Offline posted

    I repeated the exercise in another project but I couldn't reproduce the problem nor could I see any differences. I've had to restart from scratch to work around it.

  • 469350
    Suggested Answer
    Offline posted

    Hi Craig,

    cnicho said:
    Are these row scroll regions?

    Yes, it looks to me like they are.

    Are you loading a layout into the grid at run-time? The layout might be creating the ScrollRegions.

    If not, then I have seen some cases where the form designer code somehow becomes corrupted and ends up adding RowScrollRegions at design-time with invalid extents - sometimes with negative numbers.

    I'm not sure how this happens, but to solve it, try creating a RowScrollRegion at design-time by dragging and then remove it and that might clear it up.

    If not, you could edit the designer code for the form directly. Just look for RowScrollRegion in the designer code and you can probably just remove any line of code that is creating such a region. I'd strongly recommend backing up the project before you mess around with the designer code, though, just in case.