Windows 10 - Window.Titlebar-Color

Hey ho,

I’ve got a little question:
does anybody know a good Win32-Declare to change the Titlebar-Color of an application window,
running Windows 10 - but not changing the color of all Application-Titlebar-Colors as for the Explorer.exe?

e.g.:

Thanks in advance, Patric

Any program doing that would probably annoy me intensely.

Then you would be very annoyed under Windows 10 since a lot of apps - including those from Microsoft - do this.

Patric’s question is quite valid.

@Patric Lee Atrott - have you looked into the Windows Functionality Suite? You can find it here:

I am constantly annoyed by MS software, thanks. I curse it frequently.

@Peter Job - Sometimes it’s necessary to provide a color-feedback for the user - like the importance of a window, which popped up.
The ability to change the titlebar color does not inherit bad design or user feedback, it’s more like providing a more versatile feedback. On the same hand it’s necessary if your developing a “pro-app” like a productive suite with a complete different color-sheme, then you need a colored titlebar, e.g.:

@Tim Jones - thanks for your advice, but to be honest, I did not found the correct module or class, which enables me to change the titlebar-color.

BR

It looks like you have to use COM rather than declares.

To use this COM I have to use an OLEObject, or how shall I do it? (sorry new to Windows-API-Programming) :wink:

There is another way. Use a plain box window and create your own window bar.

That’s no option at this point of development.
The option of creating an own window-chrome is possible, but I’d like to provide the most common os-based design-priciples.

http://stackoverflow.com/questions/23634056/can-you-change-the-color-of-the-titlebar-of-a-userform-in-vba-using-windows-api

Fair enough - please accept my apology.

Excellent reference, @Michel Bujardet ! I’ve saved that snippet for later.

I think OLEObject is right, but I have trouble wrapping my head around COM.

At the moment I’m to stupid to convert this VB snippet into a working RB snippet, is there someone somewhere converting it successfully? :smiley: :smiley: “not used to VB and win32, declares and datatype-conversion”

The declares are already created in WFS you can download at

Use the search feature by the name of the call, for instance SetWindowLong, and you find it immediately.

[quote=253552:@Michel Bujardet]The declares are already created in WFS you can download at
https://github.com/arbp/WFS

Use the search feature by the name of the call, for instance SetWindowLong, and you find it immediately.[/quote]

[quote=253552:@Michel Bujardet]The declares are already created in WFS you can download at
https://github.com/arbp/WFS

Use the search feature by the name of the call, for instance SetWindowLong, and you find it immediately.[/quote]

This 32bit only. Any way to do this for 64bit?

You can probably adapt these fairly simple declares by replacing Integer by Uint32.

I have used Int32 with success in 64 bit declares on Windows (7 X64, 8.1 X64, Server 2012, Server 2012 R2, 10 X64)

You are right. Int32 is what Microsoft calls Long.

[quote=253552:@Michel Bujardet]The declares are already created in WFS you can download at
https://github.com/arbp/WFS

Use the search feature by the name of the call, for instance SetWindowLong, and you find it immediately.[/quote]
Can someone please provide a bit more detail on how to do this? I have tried the MaskWFS function, but it doesn’t seem to do anything.