[Webinar] Streamline your web hosting managementRegister Today

x
?
Solved

flexgrid scroll problem

Posted on 2003-02-24
12
Medium Priority
?
646 Views
Last Modified: 2007-12-19
hello! i have a problem with flexgrid i`am using 3 flexgrids i dont see a scroll in the second
i changed scroll bars = both in 3 of them
i`am using those functions

Public Sub SetGridBySql(strSql As String, dsnName As String, Grid As MSFlexGrid, arrWidth() As Integer, align As Integer)

Dim conn As New Connection
Dim rs As New Recordset
Dim i As Integer
Dim row As Integer
   
 
    conn.Open "dsn=" & dsnName
   
    rs.Open strSql, conn, adOpenStatic
   
    Grid.Rows = rs.RecordCount + 1
 
    Grid.Cols = rs.Fields.Count
   
   
    For i = 0 To rs.Fields.Count - 1
        Call SetCell(Grid, 0, i, rs.Fields(i).Name, align)
        Grid.ColWidth(i) = arrWidth(i)
    Next
   
    row = 1
    Do Until rs.EOF
        For i = 0 To rs.Fields.Count - 1
            Call SetCell(Grid, row, i, rs.Fields(i), align)
        Next
        row = row + 1
        rs.MoveNext
    Loop
   
    rs.Close
    conn.Close
   
End Sub


Public Sub SetCell(Grid As MSFlexGrid, row As Integer, col As Integer, val As String, align As Integer)
    Grid.row = row
    Grid.col = col
    Grid.Text = val
    Grid.CellAlignment = align
End Sub
0
Comment
Question by:b555
  • 3
  • 3
  • 2
  • +3
11 Comments
 
LVL 18

Expert Comment

by:Sethi
ID: 8012948
Even if you set the scroolbars to Both, the scrollbars will only appear when the columns or rows cross the client area of the flexgrid. If the rows and columns are within the client area the scrollbars wont appear. To get the scrollbars just add a few extra enteries to the flexgrid and see the scrollbar appear.
0
 

Author Comment

by:b555
ID: 8015572
i have scroll bars only in the first flex grid
i`am using the first flex to get data to the second flex
in the second flex there is a data that you cant see
because you dont have the scrollbars at all

0
 
LVL 18

Expert Comment

by:Sethi
ID: 8015814
Set the property value of "Scrollbars" to Both in the design time.
0
Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

 

Author Comment

by:b555
ID: 8016677
i tried Gridanswer.ScrollBars = flexScrollBarBoth

still dont work
iam getting crazy from it
plzzzz
0
 

Author Comment

by:b555
ID: 8016803
i tried Gridanswer.ScrollBars = flexScrollBarBoth

still dont work
iam getting crazy from it
plzzzz
0
 
LVL 18

Accepted Solution

by:
Sethi earned 200 total points
ID: 8016823
Also set this property at design time. It might be possible that you are setting this property in a procedure at runtime that is not at all getting fired. Or set this property at form load.
0
 

Expert Comment

by:CleanupPing
ID: 8901189
b555:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
Experts: Post your closing recommendations!  Who deserves points here?
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 8972680
Moderator, my recommended disposition is:

    Accept Sethi's comment(s) as an answer.

DanRollins -- EE database cleanup volunteer
0
 

Expert Comment

by:richardbc
ID: 12665425
Not a good answer as there is a problem with the flexgrid where sometimes it just does not display the scroll bars!!

I have 3 flex grids on tabs and when switching from one to another then sometimes there are no scroll bars, switch again and they are back.

Please NO stupid suggestions about settings being changed in the code or not enough lines filled.

Some intelligent comments would be very welcome.
0
 
LVL 1

Expert Comment

by:bluedragon99
ID: 12903877
have the same problem
0
 

Expert Comment

by:richardbc
ID: 12905118
I solved the problem by forcing the width to be less than the Tab container
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Question has a verified solution.

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

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
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…
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…
Suggested Courses

612 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