Hi!
I have a combobox,it should be disabled when i select a value(say "post") from another combobox.it is working in IE but not in mozilla...can anybody help me??i'm sending the code....
Regards - Select.draw(out,connectionStr, "cmbtype", "", "","", -1,"", true, "",false)
-
-
Select.draw( out, connectionStr , "cmbState", "Arial12px", "", -1, true, "", "","","","")
-
-
if(document.frmIns.cmbtype[document.frmIns.cmbtype.selectedIndex].text.indexOf("Post")!="-1")
-
{
-
-
document.getElementById('cbmState').disabled=true;
-
}
-
else
-
{
-
document.getElementById('cbmState').disabled=false;
-
}
11 2393
Hi!
I have a combobox,it should be disabled when i select a value(say "post") from another combobox.it is working in IE but not in mozilla...can anybody help me??i'm sending the code....
Regards - Select.draw(out,connectionStr, "cmbtype", "", "","", -1,"", true, "",false)
-
-
Select.draw( out, connectionStr , "cmbState", "Arial12px", "", -1, true, "", "","","","")
-
-
if(document.frmIns.cmbtype[document.frmIns.cmbtype.selectedIndex].text.indexOf("Post")!="-1")
-
{
-
-
document.getElementById('cbmState').disabled=true;
-
}
-
else
-
{
-
document.getElementById('cbmState').disabled=false;
-
}
Edit this line ... -
if(document.frmIns.cmbtype.options[document.frmIns.cmbtype.selectedIndex].text.indexOf("Post")!=-1)
-
Wish u best of luck....!!!
Edit this line ... -
if(document.frmIns.cmbtype.options[document.frmIns.cmbtype.selectedIndex].text.indexOf("Post")!=-1)
-
Wish u best of luck....!!!
Thank u...but my problem is the below line is not working in mozilla - document.getElementById('cmbState').disabled=true
'cmbState' is the string name that I gave to combobox..plz check the above code and tell me a solution...
Thank u...but my problem is the below line is not working in mozilla - document.getElementById('cmbState').disabled=true
'cmbState' is the string name that I gave to combobox..plz check the above code and tell me a solution...
Is it "cmb" or "cbm"? Check that that is indeed the id of the select and not just the name. If you're using getElementById, the ID should be present. IE erroneously uses the name for the id resulting in poor coding which causes problems in other browsers. Don't test in IE first - use it last.
Is it "cmb" or "cbm"? Check that that is indeed the id of the select and not just the name. If you're using getElementById, the ID should be present. IE erroneously uses the name for the id resulting in poor coding which causes problems in other browsers. Don't test in IE first - use it last.
it's 'cmbState' only not 'cbmstate'..and plz tell me how to give id to the select ...let me know through an example...
it's 'cmbState' only not 'cbmstate'..and plz tell me how to give id to the select ...let me know through an example...
You give an id just like you would give a name. It's simply an attribute:
[HTML]<select name="cmbState" id="cmbState"></select>[/HTML]
You give an id just like you would give a name. It's simply an attribute:
[HTML]<select name="cmbState" id="cmbState"></select>[/HTML]
Thank u but i want to know how to give id to select tag in this syntax
Select.draw( out, connectionStr , "cmbState", "Arial12px", "", -1, true, "", qryStr,new String[] {"es001"}, new String[] {"es002"}, model.getState(), Select.EMPTY_OPTION|Select.EMPTY_AT_TOP );
Thank u but i want to know how to give id to select tag in this syntax
Select.draw( out, connectionStr , "cmbState", "Arial12px", "", -1, true, "", qryStr,new String[] {"es001"}, new String[] {"es002"}, model.getState(), Select.EMPTY_OPTION|Select.EMPTY_AT_TOP );
Can you show me the code for the draw method?
Can you show me the code for the draw method?
the code for select.draw is - Select.draw( out, connectionStr , "cmbState", "Arial12px", "", -1, true, "", qryStr,new String[] {"es001"}, new String[] {"es002"}, model.getState(), Select.EMPTY_OPTION|Select.EMPTY_AT_TOP );
the code for select.draw is - Select.draw( out, connectionStr , "cmbState", "Arial12px", "", -1, true, "", qryStr,new String[] {"es001"}, new String[] {"es002"}, model.getState(), Select.EMPTY_OPTION|Select.EMPTY_AT_TOP );
No, you're probably using a library/framework of some sort which you must have included.
No, you're probably using a library/framework of some sort which you must have included.
certainly i'm using this syntax for select.draw method.......no other framework i'm using.......
certainly i'm using this syntax for select.draw method.......no other framework i'm using.......
Is this JSP or Javascript? If it's JSP, you will have some generated source for the select element. If it's Javascript, show the full code.
In fact, just show all relevant code anyway.
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Li Pang |
last post by:
I use a combobox control to populate the data. I want to
prevent to change data (freeze the data in the filed).
The only solution I have is to set Enabled property
to "False", but it gray out the...
|
by: Brian Mitchell |
last post by:
Is it possible to change the fore and back colors of a combo box when its
enabled property is set to false? I need to lock the value of my combo boxes
(and still keep its color) but that control...
|
by: Don |
last post by:
I've looked high and low for some code that will allow me to have a combobox
with a flat borderstyle. I found a few examples, but nothing that was
really usable for me. I had the following...
|
by: dbuchanan |
last post by:
VS2005
I've been reading all the help I can on the topic (MSDN, other) but I
can't make sense of this.
Desired behavior;
The user is to choose from the displayed list of the databound combobox...
|
by: Roberto |
last post by:
Hi,
using vb 2005 I'd like to have a combobox in READONLY mode, like I have for
textbox.
Combobox only has enabled property. When I turn this property false I can
not select the text in the...
|
by: Vish |
last post by:
Hi,
I need to make the text on a combobox that is disabled to be drawn with a
black color. I was not able to find any help on this online. The drawItem
seems to apply only for the dropdpwn...
|
by: Frnak McKenney |
last post by:
Can I use a bound ComboBox for both browsing and editing?
I'm working on a small, standalone database application using Visual
C#.NET 2003 and an Access data file.
In order to keep the number...
|
by: Saww |
last post by:
Hello
lately i have been trying to make a custom combobox with a few targets.
1. to create a disabled items
2. to create a seperator item
I already managed both properties items. i also managed...
|
by: Kevinp |
last post by:
I've spent the last four hours Google searching for a way to disable
items in a Combobox. I found one example in C++ which I can't get to
work and another in C# that I couldn't get to work either....
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
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$) {
}
...
|
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...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
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,...
|
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: 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,...
| |