Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / C# / December 2005

Tip: Looking for answers? Try searching our database.

How to change the color of a app's title bar?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mateusz Rajca - 20 Dec 2005 14:13 GMT
Hello,

How do I change the color of the app's title bar (where you have the Close,
Minimize and Maximize buttons) in C#?

Mateusz
Nicholas Paldino [.NET/C# MVP] - 20 Dec 2005 14:19 GMT
Mateusz,

   You could go and change the colors system-wide, but I don't think that's
what you want to do.  To do it for an individual window, you will have to
custom paint the frame.

   What you want to do is on the Form class, override the WndProc method,
and then handle the WM_NCPAINT message.  This will notify you when the frame
needs to be redrawn.  Then, you have to do it yourself, from scratch.

   Hope this helps.

Signature

         - Nicholas Paldino [.NET/C# MVP]
         - mvp@spam.guard.caspershouse.com

> Hello,
>
[quoted text clipped - 3 lines]
>
> Mateusz
Justin Creasy - 21 Dec 2005 16:44 GMT
Another way to handle it would be to completely remove the titlebar and
to create your own titlebar that is docked to the top. It's a bit of
work, but then you have complete control of the design.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.