473,386 Members | 1,609 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,386 software developers and data experts.

Transparent Textboxes

This is for a Win form.

After creating my new Textbox Class, all my instances of my new Textbox
Class are transparent. My textbox class inherits
System.Windows.Forms.TextBox, why would my text boxes be transparent? How do
I fix this?

Nov 17 '05 #1
4 2488
Hi Cadel,

Generally, the user control will not be transparent. Could you show us the
code that you implement your textbox class, and give us a simple example to
reproduce this issue?

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 17 '05 #2
class ClassTextBox : System.Windows.Forms.TextBox
{
protected override void OnEnter(System.EventArgs e)
{
base.OnEnter(e);
SelectAll();
}

}

class ClassTextBoxNum : System.Windows.Forms.TextBox
{

protected override void OnEnter(System.EventArgs e)
{
base.OnEnter(e);
SelectAll();
}

protected override void OnKeyPress(KeyPressEventArgs e)
{
if (!Char.IsDigit(e.KeyChar) && !Char.IsControl(e.KeyChar))
{
e.Handled = true;
}
base.OnKeyPress(e);
}
"Kevin Yu [MSFT]" wrote:
Hi Cadel,

Generally, the user control will not be transparent. Could you show us the
code that you implement your textbox class, and give us a simple example to
reproduce this issue?

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 17 '05 #3
Hi Cadel,

With this code snippet, it still works fine on my machine. The TextBoxes
are visible. Please try to post in the
microsoft.public.dotnet.framework.windowsforms.con trols newsgroup.

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 17 '05 #4
Okay

I hope I'm not the only person in the world to have this problem.

"Kevin Yu [MSFT]" wrote:
Hi Cadel,

With this code snippet, it still works fine on my machine. The TextBoxes
are visible. Please try to post in the
microsoft.public.dotnet.framework.windowsforms.con trols newsgroup.

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Efkas | last post by:
My application have some level : 1. MyButton class with Label inheritance 2. MyComponent as User Control loading and positionning some of MyButtons 3. MyApp loading and positionning MyComponent ...
3
by: melanieab | last post by:
Hi again, Just wondering if this was possible. I tried setting it in the Properties menu but got this response: This control does not support transparent background colors. Thanks again, Melanie
3
by: Steve Koon | last post by:
Any thoughts on getting this project to work or suggesting another method would be appreciated. Steve ========================================== Project: A Windows Form which acts as a...
7
by: Peter Oliphant | last post by:
Using MakeTransparent one can supposedly turn a color used in a Bitmap to transparent. But, it looks to me like all it does it set these pixels to the color BackColor of the Control it's attached...
8
by: Grahammer | last post by:
Is it possible to set the background of a usercontrol as transparent? I tried setting the background image of the usercontrol to a transparent GIF, but that caused MAJOR problems. I'm making...
4
by: jcrouse | last post by:
I am using the following code to move a label on a form at runtime: If myMousedown = lblP1JoyRight.Name Then If lblP1JoyRight.BackColor.Equals(Color.Transparent) Then bTransCk = True ...
3
by: Scott | last post by:
Is there a way to make a control have a transparent background? Like a text box. Thanks, Scott
4
by: ray well | last post by:
in my app i need to make a RichTextbox control transparent. i need it to be a like a pane of glass lying on a sheet of paper, where u can see everything on the sheet of paper not covered by text...
4
by: Dale | last post by:
I am creating GIF images with transparent backgrounds on-the-fly for a web app and rendering them by using System.Drawing.Image.Save(Response.OutputStream, ImageType.GIF). I am confident that...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

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.