473,320 Members | 2,161 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

label custom

I created a custom label so I can write characters in apex and also in this way:

ex.: Ac.

Now I have a problem: when my CustomLabel is in a disabled groupBox , the label does not appear disabled because the text I write with DrawText is

g.DrawString(text,usedFont, new SolidBrush(this.ForeColor),startPosition);

How can I solve this problem? How can I render a disabled label?

What is the color of a disabled label? What have I to write in OnPaint?

Thanks
Jun 26 '07 #1
3 1101
kenobewan
4,871 Expert 4TB
Welcome to TSDN. The color of disabled labels is usually white in this way they match the background of the page. Although some disabled labels are transparent so that they match any background color. If you drag your mouse over the page you can usually find them. Otherwise the server side code has not sent them to the client, so they do not have color.
Jun 26 '07 #2
Thanks, kenobewan, but this is a windows application...
what can I do in a windows application?
Jun 26 '07 #3
kenobewan
4,871 Expert 4TB
This is the reason we ask for your platform. I am a web guy but some things are the same. My belief is that if your control is not visible it would not have color. Anyone else?
Jun 27 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Adam Maltby | last post by:
Hi, I need to do a transparent label but with a difference. I have drawn on my form a custom background using CreateGraphics as I needed an ellipse looking fill in a rectangle - so the actual...
1
by: Kenneth Siewers Møller | last post by:
Hi there I have a custom label control (GradientLabel) which enherits from Label and basically just paints the background of a label in a gradient. In my code I have the following for the...
1
by: Trapulo | last post by:
Hello, I've this problem. I need to create a web app, where some text are localized in many languages. That's ok: I can use "App_Localresources" and related features, and all works. Now, I need...
1
by: suki | last post by:
How can i set the data binding property of an label to a field of a dataset (defined in a class in my project) ? In this data field, there are many entries and i want to have as much labels as...
7
by: Smokey Grindle | last post by:
How can you correctly use the <labelelement in asp.net? does the label custom control corelate to this tag correctly in the same way in that if you click it it will select the tied element? thanks
2
by: swapna_munukoti | last post by:
Hi all, I am new to asp.net. So, may be my question may be simple. But I am feeling hard to achieve this. I need to create a web custom label control, for which I have to assign new property...
3
by: bhanubalaji | last post by:
hi, I am unable to disable the text(label) in javascript..it's working fine with IE,but i am using MOZILLA.. can any one help regarding this.. What's the wrong with my code? I am...
16
by: RicercatoreSbadato | last post by:
hi all, i'd like to inherit from a label, how can I do ? i've tried: 1. making a new Web User Control, then inherit from System.Web.UI.WebControls.Label but not works! 2. creating a class...
6
by: Ian | last post by:
I am trying to get MS Access 2000 to print names and addresses onto a Dymo 400 label printer, I have set the Access Report to automatically select the correct printer, then select the label size of...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.