473,803 Members | 3,518 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Controls with Text

Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.

thanks!
Jul 17 '05 #1
8 5710
> Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.


You could put the controls on a container (say, a Frame) and disable the
Frame. However, unless you signal that the control is disabled, this
might be confusing to the user (how is he/she to know when they can use
the control and when they can't?).

Rick - MVP

Jul 17 '05 #2
true, but it is so hard to read when everything is dimmed like that.
btw, the frame idea does work! thank you.
Rick Rothstein wrote:
Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.

You could put the controls on a container (say, a Frame) and disable the
Frame. However, unless you signal that the control is disabled, this
might be confusing to the user (how is he/she to know when they can use
the control and when they can't?).

Rick - MVP

Jul 17 '05 #3
B
Another way would be to use labels to show the content, and replace them
with textboxes at the appropiate time.

B

Rick Rothstein schreef:
Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.

You could put the controls on a container (say, a Frame) and disable the
Frame. However, unless you signal that the control is disabled, this
might be confusing to the user (how is he/she to know when they can use
the control and when they can't?).

Rick - MVP

Jul 17 '05 #4
> >>Is it possible to disable a control with Text (Textbox, combobox
etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till ihit the edit key, not a problem, cept they are kind of hard to read
while disabled.

You could put the controls on a container (say, a Frame) and disable the Frame. However, unless you signal that the control is disabled, this
might be confusing to the user (how is he/she to know when they can use the control and when they can't?).

Another way would be to use labels to show the content, and replace

them with textboxes at the appropiate time.


Unless the TextBoxes are multi-lined and have scroll bars.

Rick - MVP

Jul 17 '05 #5

"B" <no****@nospam. com> wrote in message
news:dG******** ***********@ams news05.chello.c om...
Another way would be to use labels to show the content, and replace them
with textboxes at the appropiate time.
Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.



I have found it useful to Lock the text boxes and change the background color,
instead of disabling them. This allows the user to for instance copy the text,
but still provides a visual cue that it is not editable. Try changing the
background to gray when it is locked, and to white when it is unlocked.
Jul 17 '05 #6
Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.


How about putting another transparent control (ie, a transparent label or
something) over top the text box?
I think that works. Been a while..

jody
Jul 17 '05 #7
I ended up useing the frame method... works beautifully! thanks!

schmendrick wrote:
Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.

thanks!

Jul 17 '05 #8
Locking the text boxes and using a different color scheme is a good option
since it gives the user a visual cue. I think the other method of using a
frame is ok, but even still giving the user a cue when it's ok to edit
should be used. The user may thing the application has hung up and kill the
app or reboot the machine.

-Bill

"Steve Gerrard" <my********@com cast.net> wrote in message
news:6s******** ************@co mcast.com...

"B" <no****@nospam. com> wrote in message
news:dG******** ***********@ams news05.chello.c om...
Another way would be to use labels to show the content, and replace them
with textboxes at the appropiate time.
Is it possible to disable a control with Text (Textbox, combobox etc)
but not have the text fade?

I have a bunch of text boxes for a database, want them disabled till i
hit the edit key, not a problem, cept they are kind of hard to read
while disabled.

I have found it useful to Lock the text boxes and change the background

color, instead of disabling them. This allows the user to for instance copy the text, but still provides a visual cue that it is not editable. Try changing the
background to gray when it is locked, and to white when it is unlocked.

Jul 17 '05 #9

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

Similar topics

7
3566
by: Bil Muh | last post by:
Esteemede Developers, I would like to Thank All of You in advance for your sincere guidances. I am developing a software using Visual C++ .NET Standard Edition with Windows Form (.NET) template. Briefly -------------------------------------------------------------------------------------------- I need to create dynamically some controls on the forms, and display these
3
2654
by: Steve Drake | last post by:
All, I have a CONTROL that contains 1 control (Control ONE), the 1 control that it can contain 1 or 2 control (Control A and B). Control A, raises and event and Control ONE receives this event and this causes control B to be created, when this is done the VIEWSTATE is lost for CONTROL B. In the EVENT that causes CONTROL B to be created I have to set
8
4318
by: Donald Xie | last post by:
Hi, I noticed an interesting effect when working with controls that are dynamically loaded. For instance, on a web form with a PlaceHolder control named ImageHolder, I dynamically add an image button at runtime: //----- Code snippet protected System.Web.UI.WebControls.PlaceHolder ImageHolder; private void Page_Load(object sender, System.EventArgs e)
1
1757
by: bill yeager | last post by:
I did some more debugging and found the following: 1) I placed the following code in the button event just to see if I could cycle thru the datagrid control collection: <code> Dim strhello As String Dim myDataListItem As DataListItem Dim myDatagridItem As DataGridItem Dim myCheckBox As CheckBox
4
2095
by: Bass Pro | last post by:
Hi, I am creating textbox, radiobuttonlist and checkboxlist dynamically depending on data from a table. It is a questionnaire. I add the control on a Panel control during the 1st load_page event. Each question is displayed and answered, then result written to a SQL table. Then the next question is read from a table and displayed using the load_page event again. The questions display and function perfectly. The user anwers the question...
14
2371
by: Joe | last post by:
Hello All: I am trying to dynamically populate a web page with literal content and controls (textboxes and checkboxes (and eventually two buttons - the buttons do not appear in the code yet). I read an xml file and, using the values retrieved from it, determine what text should be displayed and which controls should be rendered and - most importantly - where those controls should be rendered. The ultimate goal is to have some text...
7
2479
by: Mike Bulava | last post by:
I have created a base form that I plan to use throughout my application let call the form form1. I have Built the project then add another form that inherits from form1, I add a few panel controls each with a couple of controls in them I then rebuilt my project and my new panels and all controls they contained are gone... I've looked through the Auto generated code but don't see anything that looks wrong Any body have any idea why this...
11
2145
by: VJ | last post by:
I am looking to have 2 Tab Controls on a Windows Forms.. One with Tabs on Top and another with Tabs on the side... I want them both to occupy the entire area of the form, but I need the Tab Headers to be visible for both of them .. at all times... How do I accomplish this? Also can One Tab control have Tab Headers on Top and Side.. at the same time?..That might solve this problem easily :-) Thanks Vijay
8
3593
by: Ryan | last post by:
Ok.. I have a form with lots of stuff on it; a tool strip panel, menu strip, data binding elements (dataset, binding source, table adapter), tab control with 7 tab pages, each page contains a picture box, lots of text boxes (for input).. you get the idea. All of a sudden everything on the form has disappeared, it looks like a blank, newly created form. I can still get to the properties of every item on the form using the drop-down box in...
0
1839
JimWu
by: JimWu | last post by:
I have some problems in my code. The stutiation illustrate as the followsing statement. I use two pages, one, named "upload.aspx", is including several general html input tag, whose type are "file". That mean I create server file upload controls in this page. After user choose their files, wanted to upload, and click upload button, this page will be postbacked to another page, called "edit.aspx". The code as follows. edit.aspx
0
9699
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10542
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10289
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10068
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7600
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6840
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5625
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4274
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2968
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.