Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 351
  • Last Modified:

MSflexgrid and scrolling

This may be an easy question....

I have created an application that is using the MSflexgrid control. I have created a "find" button that looks up data for a user in the flexgrid.

The lookup works great. i set my row and column by;

With MSflecgrid1
    .row = rowlocation
    .col = collocation
end with

This code puts a box round the cell I want but it does not scroll to that cell. (i.e if my data is of the screen, I have to manually scroll until I found my box that my find button found). How do I automate the scroll procedure so that it makes the row visible when I seek it?
0
lyners
Asked:
lyners
1 Solution
 
sanjeevjain1973Commented:
MS Flex grid have scrollBar Property
 You can set design time  or run time.


With MSflecgrid1

   .ScrollBar = 0 or 1 0r 2 0r 3
   .row = rowlocation
   .col = collocation
end with


if value is 0 --None
1 then Hoorizantal Scroll
2  then Vertical
3 is for both scrollbar

Sanjeev
0
 
Anthony PerkinsCommented:
You can set the TopRow property as in

With MSflecgrid1
   .row = rowlocation
   .col = collocation
   .TopRow = rowlocation
end with

0
 
sanjeevjain1973Commented:
Soory! Property Name is MsFlexGrid.ScrollBars not MsFlexGrid.ScrollBar

0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
Valliappan ANSenior Tech ConsultantCommented:
ya, agree with acperkins one. You need to set the TopRow property.
0
 
TimCotteeHead of Software ServicesCommented:
There is also a .leftcol property which can be used if the column in question has been scrolled off the visible section of the grid. In combination with .toprow you can ensure that the cell is visible no matter how many rows/cols are visible.
0
 
lynersAuthor Commented:
Exactly what I needed. Thanks!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now