Page 40 of 42 FirstFirst ... 30373839404142 LastLast
Results 1,561 to 1,600 of 1650

Thread: VBFlexGrid Control (Replacement of the MSFlexGrid control)

  1. #1561
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    I'm experimenting with vbflexgrid and it's a great ocx. In my test project, I discovered that the mouse wheel scrolls 5 lines up or down for each movement. While the "down" and "up" keys only move one line. I haven't been able to look at all 40 pages that deal with this ocx on VbForums to see if the topic has already been discussed. I would also like the mouse wheel to move only one line: is it possible?

  2. #1562
    PowerPoster
    Join Date
    Aug 2010
    Location
    Canada
    Posts
    2,891

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by fabel358 View Post
    I'm experimenting with vbflexgrid and it's a great ocx. In my test project, I discovered that the mouse wheel scrolls 5 lines up or down for each movement. While the "down" and "up" keys only move one line. I haven't been able to look at all 40 pages that deal with this ocx on VbForums to see if the topic has already been discussed. I would also like the mouse wheel to move only one line: is it possible?
    The # of mouse wheel lines used is defined by your system settings, however it appears that Krool could expose a property to allow the default to be overridden. I've submitted a pull request to Krool for this feature, but I'm not sure if it will be accepted or not.

  3. #1563

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Thanks for the pull request. For the Ocx this would mean another typelib jump. Also the space at the property page is getting rare. Would you mind if that new exposed WheelScrollLines property would be run-time only?

  4. #1564
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Krool View Post
    Thanks for the pull request. For the Ocx this would mean another typelib jump. Also the space at the property page is getting rare. Would you mind if that new exposed WheelScrollLines property would be run-time only?
    In my opinion it may not be a "property" but it could also be set in "Run-Time", if it is possible.

  5. #1565

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Update released.

    Included the run-time WheelScrollLines property. Set a value of -1 to use the system setting. (default)

    The OCX got updated and typelib jumped to 1.3
    Code:
    Object={075212A8-C1CF-444E-939D-F6046CCDBC08}#1.3#0; VBFLXGRD18.OCX

  6. #1566
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Many thanks. Works very well!
    Last edited by fabel358; Jul 12th, 2025 at 03:21 AM.

  7. #1567
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Hello. I tried setting up tooltip text for checkboxes in cells in some columns. I was able to set the tooltip, but it doesn't work when I hover over the checkbox in the cells. Is this possible?
    TIA.

  8. #1568
    Addicted Member
    Join Date
    May 2022
    Posts
    144

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Hi, did you enable showinfotips ?

  9. #1569
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Calcu View Post
    Hi, did you enable showinfotips ?
    I don't know what it does but it was enabled already, ShowInfoTips and ShowLabelTips both are True.
    I've set the tooltips with the CellToolTipText property, of the cells containing the checkboxes.

  10. #1570
    Addicted Member
    Join Date
    May 2022
    Posts
    144

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Sometimes it doesn't work for me in IDE mode, but when I compile the program it works fine.

  11. #1571

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Eduardo- View Post
    I don't know what it does but it was enabled already, ShowInfoTips and ShowLabelTips both are True.
    I've set the tooltips with the CellToolTipText property, of the cells containing the checkboxes.
    When you have ShowLabelTips and ShowInfoTips set to True then it can happen that the info tip won't show in case the text is truncated. Because the label tip has then priority.

  12. #1572
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Krool View Post
    When you have ShowLabelTips and ShowInfoTips set to True then it can happen that the info tip won't show in case the text is truncated. Because the label tip has then priority.
    In the cells of that column I have only a checkbox and no text, and I want to display a tooltip when the user hovers over the checkbox to tell something about what it will do if checked. But the tooltip appears when the user hovers in the cell outside the checkbox, and not when hovering over the checkbox itself.

    Quote Originally Posted by Calcu View Post
    Sometimes it doesn't work for me in IDE mode, but when I compile the program it works fine.
    In this case it works the same in IDE and compiled.

  13. #1573
    Member
    Join Date
    Apr 2021
    Posts
    54

    Question Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    The orientation property of the lines is not present.

  14. #1574

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Eduardo- View Post
    In the cells of that column I have only a checkbox and no text, and I want to display a tooltip when the user hovers over the checkbox to tell something about what it will do if checked. But the tooltip appears when the user hovers in the cell outside the checkbox, and not when hovering over the checkbox itself.
    Update released. Fixed. Thanks

    Quote Originally Posted by lizano diaz View Post
    The orientation property of the lines is not present.
    ?

  15. #1575
    Member
    Join Date
    Apr 2021
    Posts
    54

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    It has no property for the grid line orientation (horizontal, vertical, or both)
    Attached Images Attached Images  
    Last edited by lizano diaz; Jul 16th, 2025 at 06:09 PM.

  16. #1576
    Member
    Join Date
    Apr 2021
    Posts
    54

    Exclamation Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    The space between words (when loading long letters) is too small, it should be based on the content plus a few pixels of space.
    Attached Images Attached Images  
    Last edited by lizano diaz; Jul 16th, 2025 at 06:12 PM.

  17. #1577
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Krool View Post
    Update released. Fixed. Thanks
    Perfect! Thank you very much

  18. #1578

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by lizano diaz View Post
    It has no property for the grid line orientation (horizontal, vertical, or both)
    It's embedded within the GridLines property.
    Code:
    FlexGridLineNone = 0
    FlexGridLineFlat = 1
    FlexGridLineInset = 2
    FlexGridLineRaised = 3
    FlexGridLineDashes = 4
    FlexGridLineDots = 5
    FlexGridLineFlatHorz = 6
    FlexGridLineInsetHorz = 7
    FlexGridLineRaisedHorz = 8
    FlexGridLineDashesHorz = 9
    FlexGridLineDotsHorz = 10
    FlexGridLineFlatVert = 11
    FlexGridLineInsetVert = 12
    FlexGridLineRaisedVert = 13
    FlexGridLineDashesVert = 14
    FlexGridLineDotsVert = 15
    See there are Horz and Vert variants. Otherwise it's both when nothing is mentioned.

  19. #1579
    Member
    Join Date
    Apr 2021
    Posts
    54

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    perfect,
    It would only be necessary to adapt the the space between words (when loading long letters) is too small, it should be based on the content plus a few pixels of space.

  20. #1580

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by lizano diaz View Post
    perfect,
    It would only be necessary to adapt the the space between words (when loading long letters) is too small, it should be based on the content plus a few pixels of space.
    I don't understand this one. The text is drawn by the font selected using DrawText API. What space where?

  21. #1581
    Member
    Join Date
    Apr 2021
    Posts
    54

    Exclamation Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    The Word Wrap property doesn't work correctly with long text. The image shows two grids: a UcGridplus at the top and a vbFlexgrid at the bottom.
    Attached Images Attached Images  

  22. #1582

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by lizano diaz View Post
    The Word Wrap property doesn't work correctly with long text. The image shows two grids: a UcGridplus at the top and a vbFlexgrid at the bottom.
    Yes ?
    You may do .AutoSize to adjust the row's height.

  23. #1583
    Member
    Join Date
    Apr 2021
    Posts
    54

    Question Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    I don't know what I'm doing wrong, I've already tried all the code examples, I'm getting the data from a database (FARMINDUSTRI SA) which is a long text
    Attached Images Attached Images  

  24. #1584
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Hello everyone.
    I have both Windows 10 and Windows 11 installed on my PC. On both systems, my project uses VBFLXGRD18.ocx, and the mouse wheel scrolls perfectly. However, when I try my application on Windows 8 and/or Windows 7, the wheel no longer works. Has anyone else experienced this issue?

  25. #1585
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by fabel358 View Post
    Hello everyone.
    I have both Windows 10 and Windows 11 installed on my PC. On both systems, my project uses VBFLXGRD18.ocx, and the mouse wheel scrolls perfectly. However, when I try my application on Windows 8 and/or Windows 7, the wheel no longer works. Has anyone else experienced this issue?
    I haven't received a response. Am I the only one experiencing mouse wheel scrolling issues on Windows 7, 8, or 8.1? Or is everyone else on vacation?

  26. #1586

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by fabel358 View Post
    I haven't received a response. Am I the only one experiencing mouse wheel scrolling issues on Windows 7, 8, or 8.1? Or is everyone else on vacation?
    I can only test on xp and win 11. So I am dependent on others.

    Maybe you can find the problem yourself? Load the demo project with full source code and check what is going wrong on WM_MOUSEWHEEL.

  27. #1587
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    In WinXP, the mouse wheel in the demo works, but it doesn't in my application. Evidently, something in my application is disabling mouse wheel subclassing, and this doesn't happen in Windows 10 and 11.
    Last edited by fabel358; Aug 8th, 2025 at 02:36 AM.

  28. #1588
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Other questions. If I want to delete only text in a selection, like
    Code:
      
    With flex
         .Row = 1
         .col = 1
         .RowSel = .Rows - 1
         .ColSel = .Cols - 1
    End With
    I have to use ".Clear FlexClearClip, FlexClearText " or ".Clear FlexClearSelection, FlexClearText"?
    What is the difference between "delete" and "clear"?
    The instructions at https://helpcentral.componentone.com...ridcontrol.htm
    don't explain "FlexClearClip.": there's no instruction for VBFLEXGRID18.OCX?
    Last edited by fabel358; Aug 18th, 2025 at 12:20 PM.

  29. #1589
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Another question: do individual cells support "TAG" natively? What is "CellTag" for?

  30. #1590
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Did you perform any testing to see what those properties do? (maybe you'll save a lot of time)

  31. #1591
    Addicted Member
    Join Date
    Nov 2016
    Location
    Italy
    Posts
    234

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Eduardo- View Post
    Did you perform any testing to see what those properties do? (maybe you'll save a lot of time)
    That's what I'm doing, following Eduardo's advice to replace MsFlexGrid with VBFlexGrid18 (https://www.vbforums.com/showthread....=1#post5680371): the results aren't entirely as expected, which is why I posted these questions. Personally, I wanted to better understand the potential of VbFlexGrid... no polemic, if I've bothered anyone, I'm sorry.

  32. #1592
    PowerPoster
    Join Date
    Feb 2017
    Posts
    5,666

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by fabel358 View Post
    That's what I'm doing, following Eduardo's advice to replace MsFlexGrid with VBFlexGrid18 (https://www.vbforums.com/showthread....=1#post5680371): the results aren't entirely as expected, which is why I posted these questions. Personally, I wanted to better understand the potential of VbFlexGrid... no polemic, if I've bothered anyone, I'm sorry.
    I mean, these are not commercial products and so many times don't have a full documentation. But in most cases you can realize what the properties do by just experimenting.

    That's what I do anyway, unless the issue seems to complex. But what you are asking doesn't seem too complex to experiment, check, and see what those properties do.
    And after you figure them out, you can post your conclusions here so other users (meaning other programmers) that have the same questions in the future can search with Google (or whatever search engine or AI tool they use) and find your explanations. That's is how this cooperative work is done. Not by only one person, but everyone doing what they can.

  33. #1593
    New Member
    Join Date
    Aug 2025
    Posts
    2

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Hello Everyone,
    I've just started using VBFlexGrid and i can't seem to register the custom controls to add to a worksheet or form. I select "Register Custom" from the tool box and then the VBFLXGRD18.OCX file but get the message "The selected file does not contain any self-registering ActiveX controls."
    I am using office 365 64-bit on a Windows 11 machine.

    Many thank to anyone who can help.

  34. #1594
    PowerPoster
    Join Date
    Aug 2010
    Location
    Canada
    Posts
    2,891

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    The OCX is 32-bit and won't work with 64-bit host apps.

  35. #1595
    Member
    Join Date
    Jun 2021
    Location
    Germany
    Posts
    61

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by fabel358 View Post
    Hello everyone.
    I have both Windows 10 and Windows 11 installed on my PC. On both systems, my project uses VBFLXGRD18.ocx, and the mouse wheel scrolls perfectly. However, when I try my application on Windows 8 and/or Windows 7, the wheel no longer works. Has anyone else experienced this issue?
    Works for me on Win-7 just fine.

  36. #1596
    New Member
    Join Date
    Aug 2025
    Posts
    2

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by jpbro View Post
    The OCX is 32-bit and won't work with 64-bit host apps.
    Okay, so the OCX file is not 64 bit ready as mentioned in the initial posts?
    What needs to be done to it to make it 64 bit as reading back through the post people have this working; recompile the project?
    Sorry if this question seems a bit basic but i am a bit of a newbie with this.

  37. #1597
    Fanatic Member
    Join Date
    Jan 2016
    Posts
    834

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    hello krool
    is there a more straight way to check if at least one row is checked.
    I'm using this code todo so
    Code:
    Dim flag As Boolean, lRow%
      With VBFlexGrid1
      flag = True
        For lRow = 1 To .Rows - 1
         VBFlexGrid1.Col = 0
       VBFlexGrid1.Row = lRow
     If VBFlexGrid1.CellChecked = FlexChecked Then flag = False
      Next
      End With
      If flag = True Then
      MsgBox "You should at least check one row"
                                 
               End If
    thank you

    please excuse my little knowledge
    How to change the background color of a row once checked and which event is used on the grid?
    I mean the event like temBkColor on the listview
    this is how I'changing the background
    Code:
    Private Sub VBFlexGrid1_CellCheck(ByVal Row As Long, ByVal Col As Long)
    Dim c As Long
    Dim lRow As Long
    
    With VBFlexGrid1
     For lRow = 1 To .Rows - 1
        .Row = lRow
    
        For c = 0 To .Cols - 1
            .Col = c
           If VBFlexGrid1.CellChecked = FlexChecked Then .CellBackColor = vbRed
      
        Next c
          Next lRow
        End With
    End Sub
    I need to add this code on row check
    if row is checked change the whole row background to red
    With the code above Iget only the first column colored red.
    thank you
    Last edited by Mustaphi; Oct 18th, 2025 at 11:41 AM.

  38. #1598

    Thread Starter
    PowerPoster
    Join Date
    Jun 2012
    Posts
    2,728

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Quote Originally Posted by Mustaphi View Post
    hello krool
    is there a more straight way to check if at least one row is checked.
    I'm using this code todo so
    Code:
    Dim flag As Boolean, lRow%
      With VBFlexGrid1
      flag = True
        For lRow = 1 To .Rows - 1
         VBFlexGrid1.Col = 0
       VBFlexGrid1.Row = lRow
     If VBFlexGrid1.CellChecked = FlexChecked Then flag = False
      Next
      End With
      If flag = True Then
      MsgBox "You should at least check one row"
                                 
               End If
    thank you

    please excuse my little knowledge
    How to change the background color of a row once checked and which event is used on the grid?
    I mean the event like temBkColor on the listview
    this is how I'changing the background
    Code:
    Private Sub VBFlexGrid1_CellCheck(ByVal Row As Long, ByVal Col As Long)
    Dim c As Long
    Dim lRow As Long
    
    With VBFlexGrid1
     For lRow = 1 To .Rows - 1
        .Row = lRow
    
        For c = 0 To .Cols - 1
            .Col = c
           If VBFlexGrid1.CellChecked = FlexChecked Then .CellBackColor = vbRed
      
        Next c
          Next lRow
        End With
    End Sub
    I need to add this code on row check
    if row is checked change the whole row background to red
    With the code above Iget only the first column colored red.
    thank you
    See below optimized code blocks

    Code:
    Dim flag As Boolean, lRow%
    With VBFlexGrid1
    flag = True
    For lRow = .FixedRows To .Rows - 1
        If .Cell(FlexCellChecked, lRow, .FixedCols) = FlexChecked Then
            flag = False
            Exit For
        End If
    Next lRow
    End With
    If flag = True Then
        MsgBox "You should at least check one row"
    End If
    Code:
    Private Sub VBFlexGrid1_CellCheck(ByVal Row As Long, ByVal Col As Long)
    Dim OldFillStyle As FlexFillStyleConstants
    With VBFlexGrid1
    OldFillStyle = .FillStyle
    .FillStyle = FlexFillStyleRepeat
    If .Cell(FlexCellChecked, Row, .FixedCols) = FlexChecked Then
        .Cell(FlexCellBackColor, Row, .FixedCols, , .Cols - 1) = vbRed
    Else
        .Cell(FlexCellBackColor, Row, .FixedCols, , .Cols - 1) = -1
    End If
    .FillStyle = OldFillStyle
    End With
    End Sub

  39. #1599
    Fanatic Member
    Join Date
    Jan 2016
    Posts
    834

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    thank you Krool
    At first I got trouble with the code because I was using a fixed column.
    Then I removed the fixed column and I got it worked.
    thank you very much

  40. #1600
    Fanatic Member
    Join Date
    Jan 2016
    Posts
    834

    Re: VBFlexGrid Control (Replacement of the MSFlexGrid control)

    Hello again Krool
    I need to allow only numeric values and the decimal point in column 2 but this code doesn't seem to work
    Code:
    Private Sub VBFlexGrid1_KeyPress(KeyChar As Integer)
    With VBFlexGrid1
          If .Col = 2 Then
              Select Case KeyAscii
            Case vbKey0 To vbKey9
            Case Asc(".")
       Case Else
                KeyAscii = 0
        End Select
    
      End If
      End With
    End Sub
    thank you

Page 40 of 42 FirstFirst ... 30373839404142 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width