CommonControls (Replacement of the MS common controls) - Page 47-VBForums
Page 47 of 47 FirstFirst ... 3744454647
Results 1,841 to 1,849 of 1849

Thread: CommonControls (Replacement of the MS common controls)

  1. #1841

    Thread Starter
    Fanatic Member
    Join Date
    Jun 2012
    Posts
    848

    Re: CommonControls (Replacement of the MS common controls)

    Quote Originally Posted by Hosam AL Dein View Post
    6- Set all class modules instances to GlobalMultiuse.
    Wrong. Put all classes to "PublicNotCreatable".
    Except CommonDialog.cls. This shall be "MultiUse". (Not "GlobalMultiUse")
    Also some classes should kept "Private" such as Enumeration.cls, VTableSubclass.cls etc.
    So an advise to put everything on GlobalMultiUse is not so good.

    For the other stuff in WindowProcUserControlDesignMode it is a safety to remove subclassing in IDE at DesignTime. In the OCX this is not needed. If it keeps there it can even produce glitches. You had once an issue with the CommandButtonW that it went blank on certain steps. This was one case of that.

    Anyhow, you can proceed how you want..
    Last edited by Krool; Nov 7th, 2017 at 12:45 PM.

  2. #1842
    Lively Member Hosam AL Dein's Avatar
    Join Date
    Jul 2017
    Location
    Egypt , Cairo
    Posts
    121

    Re: CommonControls (Replacement of the MS common controls)

    Quote Originally Posted by Krool View Post
    Wrong. Put all classes to "PublicNotCreatable".
    Except CommonDialog.cls. This shall be "MultiUse". (Not "GlobalMultiUse")
    Also some classes should kept "Private" such as Enumeration.cls, VTableSubclass.cls etc.
    So an advise to put everything on GlobalMultiUse is not so good.

    For the other stuff in WindowProcUserControlDesignMode it is a safety to remove subclassing in IDE at DesignTime. In the OCX this is not needed. If it keeps there it can even produce glitches. You had once an issue with the CommandButtonW that it went blank on certain steps. This was one case of that.

    Anyhow, you can proceed how you want..
    thanks a lot krool for correction . Of course I will proceed in the way you provided . I will re-write these steps again until we come to the ideal way

  3. #1843

    Thread Starter
    Fanatic Member
    Join Date
    Jun 2012
    Posts
    848

    Re: CommonControls (Replacement of the MS common controls)

    OCX Version 1.5 now released.

  4. #1844
    New Member
    Join Date
    Feb 2009
    Posts
    4

    Re: CommonControls (Replacement of the MS common controls)

    Quote Originally Posted by Krool View Post
    OCX Version 1.5 now released.
    Thanks for the new release. Im using these controls in a new project. really appreciate your time and effort in these controls!
    Was wondering if there would be any chance of being able to add a color option for tool bar button caption text.
    thanks again.

  5. #1845

    Thread Starter
    Fanatic Member
    Join Date
    Jun 2012
    Posts
    848

    Re: CommonControls (Replacement of the MS common controls)

    Quote Originally Posted by vbLewis View Post
    Thanks for the new release. Im using these controls in a new project. really appreciate your time and effort in these controls!
    Was wondering if there would be any chance of being able to add a color option for tool bar button caption text.
    thanks again.
    You must have overlooked it. There is a ForeColor property available.
    Code:
    ToolBar1.Buttons(1).ForeColor
    This can also be defined at design-time trough the property page.

  6. #1846
    New Member
    Join Date
    Feb 2009
    Posts
    4

    Re: CommonControls (Replacement of the MS common controls)

    ahh ok. yes i missed it, i was looking under the color tab and in the main toolbar properties. The fact that it is per button makes it even cooler! Thankyou!

    Edit: I couldnt get any of the custom foreground colors to 'stick' from the property pages, only set from code, so far for toolbar button and status bar panels. is this by design?
    Last edited by vbLewis; Nov 14th, 2017 at 06:11 PM.

  7. #1847

    Thread Starter
    Fanatic Member
    Join Date
    Jun 2012
    Posts
    848

    Re: CommonControls (Replacement of the MS common controls)

    Source code for both Std-EXE and ActiveX version has been put on GitHub. Link can be found on initial post.

    Quote Originally Posted by vbLewis View Post
    I couldnt get any of the custom foreground colors to 'stick' from the property pages, only set from code, so far for toolbar button and status bar panels. is this by design?
    For me it works, so I cannot replicate your problem. What do you mean exactly? Please describe step-by-step.
    Last edited by Krool; Nov 18th, 2017 at 02:28 PM.

  8. #1848
    New Member
    Join Date
    Feb 2009
    Posts
    4

    Re: CommonControls (Replacement of the MS common controls)

    Add toolbar control to form -> click on 'custom' to open custom property page dialog -> add toolbar button -> click on colored command button to change button foreground color -> select new color for button caption -> click OK -> color dialog closes and color on command button in property sheet stays the same as it was. same for font, cannot change size.

    are you calling 'propertychanged()' when property is changed in in property sheet? it may be a storage bag permission problem on my end too.

    when i use the normal toolbar properties tab in the IDE to change font, font size is changed and works ok. but of course it doesnt edit colors for a single button, only the entire toolbar. I can set color for individual buttons from code and works good that way.

  9. #1849

    Thread Starter
    Fanatic Member
    Join Date
    Jun 2012
    Posts
    848

    Re: CommonControls (Replacement of the MS common controls)

    Quote Originally Posted by vbLewis View Post
    Add toolbar control to form -> click on 'custom' to open custom property page dialog -> add toolbar button -> click on colored command button to change button foreground color -> select new color for button caption -> click OK -> color dialog closes and color on command button in property sheet stays the same as it was. same for font, cannot change size.

    are you calling 'propertychanged()' when property is changed in in property sheet? it may be a storage bag permission problem on my end too.

    when i use the normal toolbar properties tab in the IDE to change font, font size is changed and works ok. but of course it doesnt edit colors for a single button, only the entire toolbar. I can set color for individual buttons from code and works good that way.
    Update released. Please test again. Thanks

Page 47 of 47 FirstFirst ... 3744454647

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.