Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How to paint the backcolor of a panel yellow using the Paint-event

Posted on 2014-02-02
11
Medium Priority
?
264 Views
Last Modified: 2014-02-07
Hi,

I am looking for code to paint the backcolor yellow (color = info) of a panel through the paint-event. I use c#

Peter
0
Comment
Question by:peterkiers
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
11 Comments
 
LVL 35

Expert Comment

by:gr8gonzo
ID: 39828615
Is there a reason you don't just set the BackColor property of the panel to Color.<whatever named color you want> ?
0
 
LVL 1

Author Comment

by:peterkiers
ID: 39828894
Yes, want to do that on a devexpress panel called the grouppanel. But setting the property BackColor to Info isn't working. Peter.
0
 
LVL 1

Author Comment

by:peterkiers
ID: 39831601
I've requested that this question be deleted for the following reason:

Found another way to solve this.
0
NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

 
LVL 35

Expert Comment

by:gr8gonzo
ID: 39831602
If you found a different way, please describe it here. Don't just delete the question.
0
 
LVL 1

Accepted Solution

by:
peterkiers earned 0 total points
ID: 39832251
Oke, I have chosen the DevExpress group control instead of the standard panel.
changing the back color of a GroupControl, you'll need to set the LookAndFeel.UseDefaultLookAndFeel property to false, and the LookAndFeel.Style property to Flat.

Peter
0
 
LVL 1

Author Comment

by:peterkiers
ID: 39835225
I've requested that this question be closed as follows:

Accepted answer: 0 points for peterkiers's comment #a39832251

for the following reason:

This is the right way to change the color of a groupcontrol from DevExpress.
0
 
LVL 35

Expert Comment

by:gr8gonzo
ID: 39834655
Thanks!
0
 
LVL 35

Expert Comment

by:gr8gonzo
ID: 39841293
Err... the thanks was for posting your answer. I shouldn't get points if mine wasn't the correct one.
0
 
LVL 35

Expert Comment

by:gr8gonzo
ID: 39842202
Thanks, Netminder! Sorry for the confusion. Was just trying to make sure that future people with the same problem would be able to find Peter's answer.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question