Solved

Problem placing scrollbar controls in flexgrid cells

Posted on 2003-11-14
3
423 Views
Last Modified: 2010-05-01
App consists of a single form which contains a frame and inside that frame is a flexgrid and a indexed vertical scrollbar...

I cannot get the scrollbars to appear on top of the flexgrid. If I drag the scrollbar(0) control onto the flexgrid it does appear at runtime but any children I load at runtime fail to appear ... they do show up once their top and left properties move them out of the "shadow" of the flexgrid...

I have done this before with a textbox and had no trouble, I even revisited the code for that textbox and the only difference I see is the fact that in this case I am loading my controls at runtime from an indexed array  rather than moving the same control around my grid (in the case of the textbox which works fine).

Private Sub MSFlexGrid1_Click()
    Load VScroll1(VScroll1.Count)
    VScroll1(VScroll1.Count - 1).Visible = True
    VScroll1(VScroll1.Count - 1).Top = VScroll1(VScroll1.Count - 2).Top + VScroll1(VScroll1.Count - 2).Height

    'VScroll1(VScroll1.Count - 1).Left = MSFlexGrid1.CellLeft + MSFlexGrid1.Left
    'VScroll1(VScroll1.Count - 1).Width = MSFlexGrid1.CellWidth
    'VScroll1(VScroll1.Count - 1).Height = MSFlexGrid1.CellHeight
    'VScroll1(VScroll1.Count - 1).Top = MSFlexGrid1.CellTop + MSFlexGrid1.Top
End Sub
0
Comment
Question by:mccainz2
  • 2
3 Comments
 
LVL 16

Accepted Solution

by:
Richie_Simonetti earned 250 total points
ID: 9750463
did you try with zorder property?
I didn't use scrollbars controls but if they have hwnd property you should place them over other controls/windows.
0
 
LVL 5

Author Comment

by:mccainz2
ID: 9750610
youre right richie.
I was trying to assign zorder as a variable rather than using it as a method call....
Problem fixed.
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 9750665
Glad to help. Thanks for "A" grade.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

910 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now