|
-
Dec 19th, 2016, 06:14 AM
#1241
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by fafalone
Was just noticing the columns in the ListView control weren't behaving like my normal setups... would definitely request support for column autosizing.. both the basic LVS_EX_AUTOSIZECOLUMNS style and the LVCOLUMN members you can use with it (cxMin, cxDefault, and cxIdeal)
There is already a AutoSize method in the ColumnHeader, just in case you oversaw it.
Anyhow, will check your other suggestions soon.
Thanks
-
Dec 19th, 2016, 10:24 PM
#1242
Re: CommonControls (Replacement of the MS common controls)
LVSCW_AUTOSIZE and LVSCW_AUTOSIZE_USEHEADER are entirely different than LVS_EX_AUTOSIZECOLUMNS, the latter prevents resizing to 0 (exact size is auto adjusted to the presence of image, checkbox, split button or filter too), automatically scales all columns as the ListView is resized both smaller then larger again, and is required to set the minimum width with .cxMin. The Autosize method that's there now just does a single scale operation on a single column when called. They're both useful for sure, just different.

In this pic, columns 1, 2, and 4 have been resized as small as they're now allowed with the auto-set width. Column 1 has a checkbox and a splitbutton, column 2 just a split button, and column 4 only text. No additional resizing code needed.

Here the ListView has been resized, and columns 3 and 5 have both been automatically scaled down, no other code involved.
The .cxMin allows setting a min width larger than LVS_EX_AUTOSIZECOLUMNS allows alone.
Last edited by fafalone; Dec 19th, 2016 at 10:46 PM.
-
Dec 21st, 2016, 03:01 PM
#1243
New Member
Re: CommonControls (Replacement of the MS common controls)
Hi, Krool. How can I get the VBCCR13.OCX? I am newly registered here in the forum and can't send PMs.
-
Dec 21st, 2016, 04:31 PM
#1244
Re: CommonControls (Replacement of the MS common controls)
Update released.
As the ResizableColumnHeaders property does not need anymore comctls32.dll version 6.1 or higher to work it is only consistent that also the Resizable property of a ColumnHeader will work when the comctls32.dll version is below 6.1.
The bugfix in the ResizableColumnHeaders was in the 'Get' function.
It returned always True in case the property is not supported. (not supporting = resizable)
But now as the support barrier is gone it must return of course the actual property value.
 Originally Posted by AcidJeff
Hi, Krool. How can I get the VBCCR13.OCX? I am newly registered here in the forum and can't send PMs.
I sent you a pm.
Last edited by Krool; Dec 21st, 2016 at 04:36 PM.
-
Dec 21st, 2016, 06:43 PM
#1245
New Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Krool
Update released.
As the ResizableColumnHeaders property does not need anymore comctls32.dll version 6.1 or higher to work it is only consistent that also the Resizable property of a ColumnHeader will work when the comctls32.dll version is below 6.1.
The bugfix in the ResizableColumnHeaders was in the 'Get' function.
It returned always True in case the property is not supported. (not supporting = resizable)
But now as the support barrier is gone it must return of course the actual property value.
I sent you a pm.
Thank you very much.
-
Dec 23rd, 2016, 02:35 AM
#1246
Lively Member
Re: CommonControls (Replacement of the MS common controls)
Hi Krool.
Change .Value option on OptionButtonW (also CheckboxW) does not generate a click event.
It is right?
Last edited by Romeo91; Dec 23rd, 2016 at 03:47 AM.
-
Dec 23rd, 2016, 02:45 PM
#1247
Re: CommonControls (Replacement of the MS common controls)
Update released.
 Originally Posted by Romeo91
Change .Value option on OptionButtonW (also CheckboxW) does not generate a click event.
It is right?
Yes, your are right.. Thanks for reporting.
This is now fixed, also in the OCX version. Certainly this was the last 'event loophole', hopefully.
-
Dec 26th, 2016, 09:05 AM
#1248
Re: CommonControls (Replacement of the MS common controls)
Update released.
In this update the mouse events were improved. It concerns the button and shift states for the various mouse events, such as MouseMove.
Before this update the states were retrieved using GetAsyncKeyState.
Now the states are retrieved using the wParam value of the message. (except the ALT shift state, this is retrieved using GetKeyState, not GetAsyncKeyState)
This change might be also a minor performance boost as less API calls are now involved.
However, the main improvement is that the correct button value is now passed in case the left and right mouse button are "swapped" in the windows settings.
Last edited by Krool; Dec 26th, 2016 at 04:58 PM.
-
Dec 26th, 2016, 02:53 PM
#1249
New Member
Re: CommonControls (Replacement of the MS common controls)
How do we download the files? I saw something about PM'ing you but I can click your profile and it does not give a way to PM you.
Also will these fix the problem of trying to use common dialog control in windows 7 in the VB6 IDE... gives a message that I don't have proper licensing to use the control (which makes no sense).
i.e. switch to your replacements and avoid all of the common dialog issues
-
Dec 26th, 2016, 04:48 PM
#1250
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by torrid33
How do we download the files? I saw something about PM'ing you but I can click your profile and it does not give a way to PM you.
Also will these fix the problem of trying to use common dialog control in windows 7 in the VB6 IDE... gives a message that I don't have proper licensing to use the control (which makes no sense).
i.e. switch to your replacements and avoid all of the common dialog issues
You can download the Std-EXE version at the first post of this thread. Note that the .z01.zip must be renamed to .z01 before unpacking.
The licensing issue is of course avoided when using a replacement.
Last edited by Krool; Dec 27th, 2016 at 04:55 PM.
-
Dec 27th, 2016, 05:06 PM
#1251
Re: CommonControls (Replacement of the MS common controls)
Important update released.
As of this update all key and mouse events are now improved. I recommend to replace all components..
In fact now in all message handlers is now the GetKeyState API used.
(-> GetShiftStateFromParam/GetMouseStateFromParam and GetShiftStateFromMsg/GetMouseStateFromMsg functions)
GetAsyncKeyState is therefore not used anymore.
(-> GetShiftState/GetMouseState function)
The improvement is now that always the "buffered" shift and button state is passed into the events and not the "current" state anymore.
This can be important when the application is unresponsive for some time.
Another important improvement is the "correct" mouse button state when the left and right mouse buttons are swapped in the system settings.
GetKeyState returns always the state of the logical mouse button, whereas GetAsyncKeyState returns the state of the physical mouse button.
Therefore the SM_SWAPBUTTON mapping is only done in the GetShiftState/GetMouseState (GetAsyncKeyState) function and not in the others, for info.
Sorry for the inconvenience caused and the "wrong" handling in the past.
Last edited by Krool; Dec 27th, 2016 at 05:11 PM.
-
Dec 27th, 2016, 05:38 PM
#1252
Re: CommonControls (Replacement of the MS common controls)
Krool, I've said it before but it's worth repeating. This is truly a phenomenal effort, and I'm continually impressed with your willingness to listen to suggestions for improvements.
Someday, I should attempt to follow your lead and include the MSFLXGRD.OCX and TABCTL32.OCX in this endeavor. The FiexGrid might be a bit of work, as it has some rather complex features. However, the TabControl is nothing but a fancy container that just shifts the controls off to the left when you click the different tabs. Knowing what I know about it, I could probably mock one up pretty quickly using the TabStrip and PictureBox, which you've already done.
Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.
-
Dec 27th, 2016, 08:17 PM
#1253
Fanatic Member
Re: CommonControls (Replacement of the MS common controls)
Hi Elroy , you have received my private message
Problems sending it will not let me send them, it does not appear to me as sent.
Sorry for disturbing this post
a greeting
-
Dec 28th, 2016, 01:22 AM
#1254
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Elroy
Someday, I should attempt to follow your lead and include the MSFLXGRD.OCX and TABCTL32.OCX in this endeavor. The FiexGrid might be a bit of work, as it has some rather complex features. However, the TabControl is nothing but a fancy container that just shifts the controls off to the left when you click the different tabs. Knowing what I know about it, I could probably mock one up pretty quickly using the TabStrip and PictureBox, which you've already done.
A FlexGrid replacement is already in process as said earlier. But will take some time as the first shot should be a complete replacement and quite stable.
However, that control will fit into this architecture (so the folder can included along the other controls) but will be separated from this here. As the FlexGrid is no "common control" and quite complex.
-
Dec 28th, 2016, 04:10 AM
#1255
Lively Member
Re: CommonControls (Replacement of the MS common controls)
hi, Krool
I want a copy of the newest version of the VBCCR13.OCX , it is best to bring the source code , thx
you can send me by address : 198838369(please replace with @)163.com
Best Regards
-
Dec 29th, 2016, 05:28 AM
#1256
Lively Member
Re: CommonControls (Replacement of the MS common controls)
Hi, Krool!
My project Crashes when the program exits from the event Form_KeyDown (Unload Me)
Crashes in IDE and exe-compiled.
If the exit from the program by pressing the cross, all ok.
My project is large, and are also used by other components using subsclassing, but error generate this function
Code:
Public Property Let SubclassEntry(ByVal Entry As Long, ByVal Value As Boolean)
Entry = Entry - 1
Dim EntryPointer As Long
Debug.Assert Entry >= 0 And Entry <= PropVTableCount And VTableHeaderPointer <> 0
If Me.SubclassEntry(Entry + 1) Xor Value Then
EntryPointer = UnsignedAdd(VTableHeaderPointer, Entry * 4)
If Value = True Then
Call CreateSubclass(EntryPointer, vTable(Entry), VTableOld(Entry))
Else
Call CreateSubclass(EntryPointer, VTableOld(Entry), 0)
VTableOld(Entry) = 0
End If
End If
End Property
Check please, when will be the time
P.S. https://github.com/ADIAProject/DIA
-
Dec 29th, 2016, 02:14 PM
#1257
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Romeo91
Hi, Krool!
My project Crashes when the program exits from the event Form_KeyDown (Unload Me)
Crashes in IDE and exe-compiled.
If the exit from the program by pressing the cross, all ok.
My project is large, and are also used by other components using subsclassing, but error generate this function
Code:
Public Property Let SubclassEntry(ByVal Entry As Long, ByVal Value As Boolean)
Entry = Entry - 1
Dim EntryPointer As Long
Debug.Assert Entry >= 0 And Entry <= PropVTableCount And VTableHeaderPointer <> 0
If Me.SubclassEntry(Entry + 1) Xor Value Then
EntryPointer = UnsignedAdd(VTableHeaderPointer, Entry * 4)
If Value = True Then
Call CreateSubclass(EntryPointer, vTable(Entry), VTableOld(Entry))
Else
Call CreateSubclass(EntryPointer, VTableOld(Entry), 0)
VTableOld(Entry) = 0
End If
End If
End Property
Check please, when will be the time
P.S. https://github.com/ADIAProject/DIA
I cannot replicate this crash in the Demo. Would be too easy of course if it also crashes there on Form_KeyDown. ;-)
I did not check your project, maybe you can try to narrow down the cause more on your own. For instance removing some of your other subclasses and so on.
Also it would be a try worth to use the OCX and see what happens there.
-
Dec 30th, 2016, 10:06 AM
#1258
Lively Member
Re: CommonControls (Replacement of the MS common controls)
Hi Krool.
Small bug in OptionButtonW
If set .value=true for OptionButtonW, when close form and reopen i see that in Gui .value=false (no dot), in options .value=true
-
Dec 30th, 2016, 02:49 PM
#1259
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Romeo91
Small bug in OptionButtonW
If set .value=true for OptionButtonW, when close form and reopen i see that in Gui .value=false (no dot), in options .value=true
Fixed. Thank you.
Also small bug in CheckBoxW. The Click event was not fired when changing the Value property by code and when the DrawMode is OwnerDraw.
The OCX version was also updated for this bug.
-
Jan 2nd, 2017, 07:43 PM
#1260
Lively Member
Re: CommonControls (Replacement of the MS common controls)
hello Krool, how can I get an "OCX" version of CommonControls (Replacement of the MS common controls) ?
-
Jan 6th, 2017, 11:28 AM
#1261
Lively Member
Re: CommonControls (Replacement of the MS common controls)
@Krool
I want to use this ocx but before using i have 2 questions:
1) is this ocx completely free? should we buy it? (because i saw a screen shot with a title bar that there was a demo text in it)
2) did you write it yourself? or copied from another company website to this thread?
Thank you
-
Jan 6th, 2017, 01:21 PM
#1262
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Mahdi Jazini
1) is this ocx completely free? should we buy it? (because i saw a screen shot with a title bar that there was a demo text in it)
Its free, nothing to buy. Where did you see the screen shot with demo text? You mean the demo project at first page? This is in fact the Std-EXE version and the leading version and the OCX derived from this from time to time. (Half or full year)
 Originally Posted by Mahdi Jazini
2) did you write it yourself? or copied from another company website to this thread?
It's written by myself. Though I got inspired by vbaccelerator, which is also open source free.
-
Jan 7th, 2017, 01:46 AM
#1263
Lively Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Krool
Where did you see the screen shot with demo text? You mean the demo project at first page? This is in fact the Std-EXE version and the leading version and the OCX derived from this from time to time. (Half or full year)
Yes, at the first page
 Originally Posted by Krool
It's written by myself. Though I got inspired by vbaccelerator, which is also open source free.
Thank you for writing this project. it can help me so much because it supports unicode
Again thank you for sharing it free. God bless you
-
Jan 7th, 2017, 01:18 PM
#1264
-
Jan 7th, 2017, 01:41 PM
#1265
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Mahdi Jazini
Krool your ocx was so useful but there is a problem in ListBoxW
It doesn't support text align
Persian and Arabic languages need this property
Could you add these properties:
TextAlign
TextDirection
If a text starts with a number:
for example: 2 کرول
at this time (TextAlign=Right) can't help but (TextAlign=Right) + (TextDirection=RTL) can help very much
TNX 
There is a RightToLeft property available in ListBoxW.
-
Jan 7th, 2017, 05:24 PM
#1266
Re: CommonControls (Replacement of the MS common controls)
Update released.
Quite important bugfix for ListBoxW control. When the control has no items (empty) the .NewIndex property returned 0 instead of -1.
The ComboBoxW control was not affected, it already returned correctly -1 in this case.
Also enhanced the ListBoxW control when using it as an OLE drop target.
Included the InsertMark/InsertMarkColor property and HitTestInsertMark function.
The InsertMark property and the HitTestInsertMark function have both an optional 'After' parameter.
The demo project has been extended so that the ListBoxW control accepts OLE drop, showing the InsertMark functionality.
Last edited by Krool; Jan 7th, 2017 at 05:37 PM.
-
Jan 7th, 2017, 08:23 PM
#1267
Addicted Member
Re: CommonControls (Replacement of the MS common controls)
If there is a print preview of the good, such as support for DataGrid, mshflexgrid.
-
Jan 8th, 2017, 12:54 AM
#1268
Lively Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Krool
There is a RightToLeft property available in ListBoxW. 
But there is no this property in your ListboxW
This property is only in the classic listbox:
Code:
list1.RightToLeft=True
Where can i find the above property in your ocx?
TNX
-
Jan 8th, 2017, 01:12 AM
#1269
Hyperactive Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Mahdi Jazini
But there is no this property in your ListboxW
This property is only in the classic listbox:
Code:
list1.RightToLeft=True
Where can i find the above property in your ocx?
TNX 
It is not implemented in the OCX ListboxW yet. It is implemented in the Std-EXE ListboxW.
-
Jan 8th, 2017, 01:16 AM
#1270
Lively Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by chosk
It is not implemented in the OCX ListboxW yet. It is implemented in the Std-EXE ListboxW.
How to use Std-EXE ListboxW ?
What's Std-EXE ?
Can you help me? 
Tnx
-
Jan 8th, 2017, 04:29 AM
#1271
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Mahdi Jazini
How to use Std-EXE ListboxW ?
What's Std-EXE ?
Can you help me?
Tnx
Yes, as chosk pointed out, the RightToLeft property is not available in the OCX yet. (only Std-EXE)
When you run the Demo project in the first page, that is a Std-EXE project. And there is also the Std-EXE ListBoxW used.
Just include the necessary components into your project. You actually don't need the whole OCX if you are just looking to implement a Unicode ListBox..
 Originally Posted by ChenLin
If there is a print preview of the good, such as support for DataGrid, mshflexgrid.
what is a print preview of the good? There is only a PageSetup and a Print dialog in CommonDialog.cls, no print preview..
-
Jan 8th, 2017, 08:25 AM
#1272
Lively Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Krool
Yes, as chosk pointed out, the RightToLeft property is not available in the OCX yet. (only Std-EXE)
When you run the Demo project in the first page, that is a Std-EXE project. And there is also the Std-EXE ListBoxW used.
Just include the necessary components into your project. You actually don't need the whole OCX if you are just looking to implement a Unicode ListBox..
Ahhhh
Tnx, i have got it
Std-EXE = The standard exe (Open Source) version
I have found the RightToLeft property in it
Thank you
-
Jan 9th, 2017, 03:21 AM
#1273
-
Jan 9th, 2017, 04:23 AM
#1274
Fanatic Member
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Mahdi Jazini
@Mahdi Jazini : Love God is good. But please keep it in our hear instead of waste VBForums resource, the sentence occupied space and my mobile data flow, we normally use the signature for links of useful stuff.
-
Jan 9th, 2017, 01:32 PM
#1275
Lively Member
Re: CommonControls (Replacement of the MS common controls)
The following example not working:
Code:
RichTextBox1.RightToLeft = True
RichTextBox1.Text = "Krool"
The following example worked fine:
Code:
RichTextBox1.RightToLeft = True
RichTextBox1.Text = "Krool"
RichTextBox1.Text = RichTextBox1.Text & ""
!!!!
-
Jan 9th, 2017, 05:20 PM
#1276
Re: CommonControls (Replacement of the MS common controls)
Update released.
The standard windows list box control has a 16-bit barrier when dragging the scroll box. (SB_THUMBPOSITION and SB_THUMBTRACK)
That limitation could be circumvented in the ListBoxW control by intercepting WM_HSCROLL/WM_VSCROLL and using the 32-bit GetScrollInfo function.
Also included the ScrollTrack property which controls if SB_THUMBTRACK will set the new position. (If set to False only SB_THUMBPOSITION has an effect)
Setting ScrollTrack to False could be an performance boost when using some code in the Scroll event.
@ Mahdi Jazini,
changing the RightToLeft in the RichTextBox control at run-time can be strange as the TextRTF itself does hold some rtl information.
The safest way to change it at run-time is to do following:
Code:
RichTextBox1.TextMode = RtfTextModePlainText
RichTextBox1.RightToLeft = True
RichTextBox1.TextMode = RtfTextModeRichText
Last edited by Krool; Jan 10th, 2017 at 02:31 PM.
-
Jan 10th, 2017, 09:51 AM
#1277
Hyperactive Member
Re: CommonControls (Replacement of the MS common controls)
Hi Krool,
Any chance of an earlier release of the OCX with the LabelW VerticalAlignment property?
-
Jan 10th, 2017, 02:42 PM
#1278
Re: CommonControls (Replacement of the MS common controls)
Update released.
the 32-bit thumb scrolling support works now properly in each "scenario" in the ListBoxW control.
Means vertical scolling is always 32-bit.
Horizontal scrolling is only 32-bit when also the MultiColumn property is set to True.
Else it remains 16-bit, which is the case for 'HorizontalExtent' scrolling. And that should certainly be sufficient. 
Sorry for the confusion..
 Originally Posted by chosk
Any chance of an earlier release of the OCX with the LabelW VerticalAlignment property?
I also think it gets time to bring out the next OCX release.
But as the forum rules are restricted about closed binaries I am thinking of publishing the source code along the binary.
This way I could upload everything in "UtilityBank - Components" and make a link from here to there.
What you guys think?
-
Jan 10th, 2017, 04:21 PM
#1279
Re: CommonControls (Replacement of the MS common controls)
 Originally Posted by Krool
I also think it gets time to bring out the next OCX release.
But as the forum rules are restricted about closed binaries I am thinking of publishing the source code along the binary.
This way I could upload everything in "UtilityBank - Components" and make a link from here to there.
What you guys think?
x2 from me.
thanks either way!
-
Jan 10th, 2017, 10:50 PM
#1280
New Member
Re: CommonControls (Replacement of the MS common controls)
Hi Krool,
I wold love a new OCX version with the updates. I wold also like to know if the Palettes for selecting colors in the new .OCX would now work.
Thanks for the great work!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|