Solved

MSflexgrid and scrolling

Posted on 2001-09-10
6
336 Views
Last Modified: 2012-06-27
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
Comment
Question by:lyners
6 Comments
 
LVL 1

Expert Comment

by:sanjeevjain1973
ID: 6473251
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
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 100 total points
ID: 6473277
You can set the TopRow property as in

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

0
 
LVL 1

Expert Comment

by:sanjeevjain1973
ID: 6473278
Soory! Property Name is MsFlexGrid.ScrollBars not MsFlexGrid.ScrollBar

0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 9

Expert Comment

by:Valliappan AN
ID: 6473282
ya, agree with acperkins one. You need to set the TopRow property.
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 6473650
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
 
LVL 1

Author Comment

by:lyners
ID: 6477648
Exactly what I needed. Thanks!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
using Access 8 83
How to set the sa password in a vb6 code for sql connection 9 62
Hide vba in gp 7 113
how to know if my Checkbox is True in VB6.0? 9 65
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question