473,806 Members | 2,386 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Disable/enable Textbox Buttons

11 New Member
Hi guys
can someone kindly help me about my code it seems incomplete or i just can make it right .I try using the disabled property of the textbox yes it workss, it disable it but when i set it to false like disabled="false " it does not enable the textbox.This is my code



<p><input type="text" name="txtbox1" size="20" disabled="true" >
<input type="button" value="Click" name="B3" disabled="true" > Operator</p>
<p><input type="text" name="txtbox2" size="20"disabl ed="false">
<input type="button" value="Click" name="B4" disabled="false "> Supervisor</p>


thanks and regards
metalwing
Jan 17 '07 #1
5 14284
shweta123
692 Recognized Expert Contributor
Hi,

Don't give any value for Disabled property.e.g. <Input type="Text" Disabled>
If you want to make the Textbox Enabled just dont give anything there.
Jan 17 '07 #2
metalwing12
11 New Member
Hi,

Don't give any value for Disabled property.e.g. <Input type="Text" Disabled>
If you want to make the Textbox Enabled just dont give anything there.

hi shweta123

yahh i already did that what i want to do is that when i click the button in my asp it will disable the previous active button and textboxes..But it seems that whatever propertyi work with wether it is disabled or enable regardless of value(true or false) it seems not accepting the value..tnkss hope you can help me..

metalwing
Jan 17 '07 #3
shweta123
692 Recognized Expert Contributor
Hi,

I am not getting where exactly its going wrong .You can try these lines
be4 making textbox or any control enabled or disabled.

for(i=0;i<form. elements.length ;i++)
{
if(form.element s[i].disabled="fals e")
form.elements[i].disabled="true ";
}

Shweta
Jan 18 '07 #4
metalwing12
11 New Member
Hi,

I am not getting where exactly its going wrong .You can try these lines
be4 making textbox or any control enabled or disabled.

for(i=0;i<form. elements.length ;i++)
{
if(form.element s[i].disabled="fals e")
form.elements[i].disabled="true ";
}

Shweta
hi

well what im trying to do is that i have 4 textboxes and buttons
the first textboxes and buttons is enable and the rest disabled.when i click the first button it will enable the second textbox and button while disabling the first textbox and button.
hope you can help me..

thanks and regards
metalwing
Jan 19 '07 #5
MATTXtwo
83 New Member
how about vbscript to enabled and disabled textbox outside of textbox control
like<% if session("Pwd")= "" then textbox1.disabl ed=true end if%>
and also assign value to textbox outside of textbox control?
Sep 24 '08 #6

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

Similar topics

7
13938
by: Michael | last post by:
I'm exploring how to programmatically disable/enable devices in a system using C#. -MH
2
1821
by: metalwing12 | last post by:
Hi guys can someone kindly help me about my code it seems incomplete or i just can make it right .I try using the disabled property of the textbox yes it workss, it disable it but when i set it to false like disabled="false" it does not enable the textbox.This is my code <p><input type="text" name="txtbox1" size="20" disabled="true"> <input type="button" value="Click" name="B3" disabled="true"> Operator</p> <p><input...
6
1851
soramaster
by: soramaster | last post by:
How do I make it where something disabled until you put some kind of code in, S/N? Like on some program trials it will need a code to enable some buttons.functions,etc. On mine I want some stuff disabled until you enter a code in to enable it. Like I want one of my command buttons disabled. Thanks
3
11668
by: Pietro | last post by:
Hi all, First of all I'd like to thank you very very much ,as finally after many years of searching,I could find a code to disable/enable the shift key,but actually i cannot use the code as I'm very new to VBA,i tried to follow the instructions reported in the code,but i got no result,i still can use the shift key,can you explain in details how to use it correctly to enable/disable users from pressing shift key to view database windw?,the...
5
2148
by: Zuhaib Hyder | last post by:
how ti disable aspnet textbox for prevent user input, but want to set value from javascript calendar at the moment it shows updated selected value from javascript calendar, but when i save data into database textbox returns old date... not the updated one.... how to solve this?
0
1359
by: Alexander Vasilevsky | last post by:
Can to disable/enable smoothing font in the WPF? http://www.alvas.net - Audio tools for C# and VB.Net developers
10
5102
by: viki1967 | last post by:
Disable/enable icon.gif Hi all. I have this form in the page.htm: <form action="form.asp" method="post" onsubmit="return(validateForm(this));"> <select size="1" name="t_im" onchange="Form()">
1
2433
AR Ratheesh
by: AR Ratheesh | last post by:
Hi, Please help me to disable / enable task manager and Explore for a internet Cafe management project. Thanks in advance..
0
9719
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
9597
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10618
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
10371
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
10110
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...
0
9187
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7649
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
6877
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();...
3
3008
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.