-
Re: CommonControls (Replacement of the MS common controls)
-
Re: CommonControls (Replacement of the MS common controls)
Hi Krool.
Why such changes in a set?
I used thisa kontrol, big problems in it didn't notice.
Quote:
Originally Posted by
Krool
List of revisions:
11-Feb-2015
...
- Removed the ToolTip control.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Hi Krool.
Why such changes in a set?
I used thisa kontrol, big problems in it didn't notice.
I dont know why he removed it, but I know I had to stop using it because when debugging my program for any leaks, the GDI Objects in task manager would grow every time I used it and never go back down. Even when the form was closed and everything cleaned up. Once I removed the tooltip from the form the GDI Objects would rise and shrink like normal.
Not sure if that is the reason he removed it, but for me that is one of the reasons I stopped using it.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
Romeo91
Hi Krool.
Why such changes in a set?
I used thisa kontrol, big problems in it didn't notice.
There are plenty of ToolTip control classes around the web. Thus it is not really necessary to include it in my project. There were some problems with it also.
Anyhow, you have a backup of the control? If not I could send you a PM with it.
-
Re: CommonControls (Replacement of the MS common controls)
Krool, any plans to replace the winsock control?
-
Re: CommonControls (Replacement of the MS common controls)
@brandoncampbell
Not really necessary.
See here, here and here.
-
Re: CommonControls (Replacement of the MS common controls)
Just came across The commandButtonW SplitButton Property, it looks very interesting how do I add items and/or check what is selected?
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
... how do I add items and/or check what is selected?
Create an invisible popup menu control (and its submenus) using the IDE's Menu Editor dialog, then pop it up when the CommandButtonW's DropDown event fires. Position the menu like this:
Code:
Private Sub CommandButtonW1_DropDown()
With CommandButtonW1
PopupMenu mnuPopup, vbPopupMenuRightButton, .Left, .Top + .Height
End With
End Sub
-
Re: CommonControls (Replacement of the MS common controls)
CommandButtonW has no MaskColor Property, is there a way around it?
can I use an imagelist instead, if so how do I assign the image index to the button?
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
CommandButtonW has no MaskColor Property, is there a way around it?
I haven't tested this, but I believe a MaskColor property is no longer necessary because the CommandButtonW's Picture property already supports transparency in icons/bitmaps.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
Bonnie West
I haven't tested this, but I believe a MaskColor property is no longer necessary because the CommandButtonW's Picture and PictureAndCaption properties already supports transparency in icons/bitmaps.
transparency is only supported in icons not BMP files, and PNG files are not supported at all (although it would be great to see it added)
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
transparency is only supported in icons not BMP files, ...
Transparency is indeed supported for BMP files. However, it can't be just any regular BMP file, it has to be a pre-multiplied ARGB BMP file.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
Bonnie West
Transparency is indeed supported for BMP files. However, it can't be just any regular BMP file, it has to be a pre-multiplied ARGB BMP file.
pre-multiplied ARGB BMP ? never heard of it (in vb6), could you elaborate please , or at least point me to the right direction.
tested it, and I am getting invalid picture.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
CommandButtonW has no MaskColor Property, is there a way around it?
can I use an imagelist instead, if so how do I assign the image index to the button?
You can use a ImageList. The first image of the ImageList will be used automatically. If the ImageList has multiple images than the CommandButtonW uses for each state a certain index.
-
Re: CommonControls (Replacement of the MS common controls)
how do I set RightToLeft Property to the controls?
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
how do I set RightToLeft Property to the controls?
You can't. The controls are same as the ambient RighToLeft property.
-
2 Attachment(s)
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
pre-multiplied ARGB BMP ? never heard of it (in vb6), could you elaborate please , or at least point me to the right direction.
Sure. Check out the links in this Google search.
Attached below is a demo project and some pARGB BMP samples. Extract the archive contents to the ComCtlsDemo folder in Krool's ComCtlsDemo.rar.zip.
Oh, BTW, I created the pARGB BMPs with Pixelformer.
-
Re: CommonControls (Replacement of the MS common controls)
I'm sorry for the slightly off topic, it's my first post here.
Could someone please tell me how can I add the this control replacement scheme to both a new vb6 project and also to an existent big vb6 project.
I do have an old vb6 big project, it's Profound a GUI that interacts to a c++ checkers/draughts variant (spanish).
If it is an easy thing to do I really could get rid of that old MS controls dependency.
https://www.youtube.com/watch?v=bu2Nk1q5Y7Y
best regards,
Alvaro
-
2 Attachment(s)
Re: CommonControls (Replacement of the MS common controls)
I used krool's OpenPrinterEx in CommonDialog class.But the printer dialog failed to assign my printer "\\192.4.4.143\Canon iR2002/2202 UFRII LT(1)".I watched the return printer name is limited 30 Characters of "\\192.4.4.143\Canon iR2002/220"what is the reason?
Edited: Look like the string is being truncated. But I don't know the reason.
-
1 Attachment(s)
Re: CommonControls (Replacement of the MS common controls)
Hi Krool and thank you for this fantastic piece of software!
I have only a problem in embedding your code in my old ocx-dependent:
Using the With instruction:
Code:
With MainForm.TabStrip.Tabs(TabsCounter)
.... code
End With
I have this error:
Attachment 125855
Thank you in advance for considering this problem.
Gigirex
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
gigirex
I have this error:
Can you post the exact line and the entire procedure where that error occurs? Can you also please provide additional details about your issue?
-
Re: CommonControls (Replacement of the MS common controls)
Thank you for replying.
The error is precisely on the With instruction.
As workaround I have directly assigned values without the width prefix and works without problems:
Code:
Let MainForm.TabStrip.Tabs(TabsCounter).Caption = strTab(TabsCounter)
..but it don't work if I use the With instruction:
Code:
With MainForm.TabStrip.Tabs(TabsCounter)
Let .Caption = strTab(TabsCounter)
End With
..and the .key variable is read-only. Is not very important, but in the original ocx is r/w.
Thanks again.
Gigirex
-
Re: CommonControls (Replacement of the MS common controls)
hello
I just found by chance a bug in "CommonDialog.ShowOpen"
It is not possible to use "FileName" as the default file.
The simple solution is to add
Code:
Public Function ShowOpen() As Boolean
Dim Buffer As String, Filter As String
Buffer = String(PropMaxFileSize, vbNullChar)
Mid$(Buffer, 1) = PropFileName' Code add.
Dim OFN As OPENFILENAME
With OFN
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
gigirex
The error is precisely on the With instruction.
I cannot confirm this error. By me its working. Anyone else problem on this?
Quote:
Originally Posted by
lrd_VB6
I just found by chance a bug in "CommonDialog.ShowOpen"
It is not possible to use "FileName" as the default file.
Thank you. Will fix this issue. However, the save dialog did not had this bug.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
Krool
I cannot confirm this error. By me its working. Anyone else problem on this?
I couldn't reproduce Gigirex's "UDT not defined" error as well. I don't see why the With block he posted would throw such an error. At any rate, it seems he has already figured out a workaround so I guess this issue is resolved.
-
Re: CommonControls (Replacement of the MS common controls)
Refer to #659
Code:
NewPrinterName = Mid$(DNAMES.wExtra, _
DNAMES.wDeviceOffset - DNAMES.wDriverOffset + 1)
NewPrinterName = VBA.Left$(NewPrinterName, _
InStr(NewPrinterName, Chr$(0)) - 1)
-
Re: CommonControls (Replacement of the MS common controls)
hello
Just for information:
Why do this:
Code:
Buffer = String(PropMaxFileSize, vbNullChar)
If Not PropFileName = vbNullString Then
If Len(PropFileName) > (PropMaxFileSize + 1) Then
Length = PropMaxFileSize * 2
Else
Length = LenB(PropFileName)
End If
CopyMemory ByVal StrPtr(Buffer), ByVal StrPtr(PropFileName), Length
End If
while the following code does the same thing?
Code:
Buffer = String(PropMaxFileSize, vbNullChar)
Mid$(Buffer, 1) = PropFileName
VB guaranteed that the replacement string will never exceed the original chain.
(that is what is written in Help)
For proof:
Code:
a$="123456789"
?lenb(a$)
18
mid$(a$,1)="09876543210"
?a$
098765432
?lenb(a$)
18
c$=vbnullstring
mid$(a$,1)=c$
?a$
098765432
?lenb(a$)
18
Finally, in VBCCR11.ocx, "CommonDialog" does not have the event "InitDialog".
It is normal?
cordially
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
lrd_VB6
in VBCCR11.ocx, "CommonDialog" does not have the event "InitDialog".
It is normal?
Yes. The event "InitDialog" will be on VBCCR12.OCX. (not yet released)
-
Re: CommonControls (Replacement of the MS common controls)
I have noticed that the ImageList is causing a lot of problems(Crashing, and by that sometimes corrupting the frm/frx file), has anyone had the same experience.
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Yes. The event "InitDialog" will be on VBCCR12.OCX. (not yet released)
will projects using VBCCR11.OCX automatically update to VBCCR12.OCX?
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
ishalom
I have noticed that the ImageList is causing a lot of problems(Crashing, and by that sometimes corrupting the frm/frx file), has anyone had the same experience.
Please describe the exact steps what causes the crashs. Thanks
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
Originally Posted by
Jonney
I used krool's OpenPrinterEx in CommonDialog class.But the printer dialog failed to assign my printer "\\192.4.4.143\Canon iR2002/2202 UFRII LT(1)".I watched the return printer name is limited 30 Characters of "\\192.4.4.143\Canon iR2002/220"what is the reason?
Edited: Look like the string is being truncated. But I don't know the reason.
Update released.
This issue is now fixed. Thanks to Jonney for the solution.
-
Re: CommonControls (Replacement of the MS common controls)
-
Re: CommonControls (Replacement of the MS common controls)
Update released.
Found out that in the VisualStyles.bas and in CommandButtonW.ctl (graphical style only) in case the button is disabled the 'DisabledPicture' was drawn in disabled state, instead it should be drawn normally or masked. Only when there is no 'DisabledPicture' the drawing should be in disabled state in case the button is disabled.
This issue is now fixed. Thus the behavior now matches to the intrinsic VB control.
-
Re: CommonControls (Replacement of the MS common controls)
Ever figure out anything about why all the IPPB stuff is always throwing errors ?
VTableHandle.IPPB_GetDisplayString.Error2->Type mismatch
VTableHandle.IPPB_GetPredefinedStrings.Error2->Type mismatch
"Set ShadowIPerPropertyBrowsingVB = This" is the number one source of the errors. Click on control after clicking something else first, bunch of those errors scroll by, 9/10 properties disappear. Have to close and reopen form to get them back.
-
Re: CommonControls (Replacement of the MS common controls)
Hi, can you provide the events for this great control. I am using this for it's Treeview control as a work-around to the Win7/8 64 system issues with the old Treeview control, what a MS mess...
However, I cannot seem to get the Click event to work as with the VB 5/6 MS Treeview control. And, when I End the EXE Program or when in VB design mode, I get a Windows (7/8) error that checks for a problem sol'n, but can't find. Must then terminate the program.
Thank you so much, I see this as the ultimate sol'n to what MS does.
Again, thanks... Paul
-
Re: CommonControls (Replacement of the MS common controls)
Quote:
I cannot seem to get the Click event to work as with the VB 5/6 MS Treeview control.
Does the Click event fire or not? Or does it not work the same only?
What about the other events. Please more details. Thanks
Quote:
And, when I End the EXE Program or when in VB design mode, I get a Windows (7/8) error that checks for a problem sol'n, but can't find. Must then terminate the program.
Do you call the InitVisualStyles method at startup in the EXE?
Quote:
Originally Posted by
fafalone
Ever figure out anything about why all the IPPB stuff is always throwing errors ?
VTableHandle.IPPB_GetDisplayString.Error2->Type mismatch
VTableHandle.IPPB_GetPredefinedStrings.Error2->Type mismatch
"Set ShadowIPerPropertyBrowsingVB = This" is the number one source of the errors. Click on control after clicking something else first, bunch of those errors scroll by, 9/10 properties disappear. Have to close and reopen form to get them back.
Is this also happening in the Demo project?
-
Re: CommonControls (Replacement of the MS common controls)
What are the events for TreeView (such a Node Click)? When Ending the program, all crashes, any fix. Thanks, Paul
-
Re: CommonControls (Replacement of the MS common controls)
The issue is I can't find the code for the node click event. I only get 4 options, such as gotfocus, etc...
Have no idea on the IniVisualStyle code is or location to place in the EXE.
We have a major program for chemical engineers that does not work with the latest MS release of Comctl... We and our Clients are panicking
Do you know anyone that can work with us? We are ChemE's and this is beyond us...
Thanks, Paul
-
Re: CommonControls (Replacement of the MS common controls)
This article seems to provide the reasons for the crash when closing the program...
http://www.vbaccelerator.com/home/VB...wn/article.asp
But I don't like the sol'n... Paul