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

Show hidden combo boxes when status selected in combo box

Hi,

I have a combo box which has status(daily, monthly, weekly) enabled and a combo hidden.on change,ie., If i try to select weekly in the combo, it should enable the hidden combo with all the weekdays, and similarly if I try to select on monthly, the hidden combo should show, the dates from 1 to 30.

Can you help me out in solving this issue?
Sep 25 '07 #1
4 2157
r035198x
13,262 8TB
Hi,

I have a combo box which has status(daily, monthly, weekly) enabled and a combo hidden.on change,ie., If i try to select weekly in the combo, it should enable the hidden combo with all the weekdays, and similarly if I try to select on monthly, the hidden combo should show, the dates from 1 to 30.

Can you help me out in solving this issue?
Java != Javascript

Moved to Javascript forum.
Sep 25 '07 #2
dmjpro
2,476 2GB
Hi,

I have a combo box which has status(daily, monthly, weekly) enabled and a combo hidden.on change,ie., If i try to select weekly in the combo, it should enable the hidden combo with all the weekdays, and similarly if I try to select on monthly, the hidden combo should show, the dates from 1 to 30.

Can you help me out in solving this issue?
Welcome to TSDN!

Post your code you have so far with Posting Guidelines.
And point out your problem in details.

Kind regards,
Dmjpro.
Sep 25 '07 #3
andho
34
You could create two variables like so:
Expand|Select|Wrap|Line Numbers
  1. var comboweekdays = '<option value="sun">Sunday</option><option value="mon">Monday</option><....';
  2. var combodaysofmonth = '<option value="1">1</option><option value="2">2</option>....';
and so on. Then you can assign comboweekdays to combo.innerHTML like so
Expand|Select|Wrap|Line Numbers
  1. combo.onstatechanged = function () {
  2.   if (combo.option[combo.selectedIndex] == 'weekly') {
  3.     combo2.innerHTML = comboweekdays;
  4.   } else if (combo.option[combo.selectedIndex] == 'monthly') {
  5.     combo2.innerHTML = combodaysofmonth;
  6.   }
  7. }
Sep 25 '07 #4
acoder
16,027 Expert Mod 8TB
Changed the thread title to better describe the problem. Please use a good thread title.
Sep 25 '07 #5

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

Similar topics

5
by: Shreekant Patel | last post by:
Hello, I am new to the advanced level of access, and I have quite a few changes to make to an existing database. The current database's main form needs to have additional check boxes added to...
0
by: Tom | last post by:
I have some very strange issues with combo boxes on a tab control. Here's the scenario: I have a Windows Forms form that has a tab control on it, with two (2) tabs. Tab 2 happens to have a number...
7
by: Ausclad | last post by:
Ok, ill try again..... It seems fairly simple. I have two combo boxes in a datagrid. The datagrid is bound to a a table in a dataset. The two combo boxes are bound to a single data table...
21
by: ducky | last post by:
I am working with a form that contains two text boxes and a combo box. I want the combo box to only show you the options that are available to you after you enter two seperate values in the previous...
6
by: Dave | last post by:
I want to put the information that the user selects in my combo boxes into a subform that lies on the same form as the combo boxes. Thanks for your help already, Dave
1
by: Dave | last post by:
Hello all, First I'd like to apologize...This post was meant to be put in my previous post, but I tried many times without success to reply within my previous post. Now here goes... I have a...
2
by: Dave | last post by:
I have 3 tables of information feeding into 4 combo boxes on my main form (DR Form). I have as many list boxes (acting as text boxes) as there are fields in each one of the 3 tables. Once...
0
by: Dawnyy | last post by:
I have a form which is bound to a dataset. I am filling the forms dataset on Form_Load event. On my form I have combo boxes which I am setting by running a stored procedure to return a datatable,...
3
kcdoell
by: kcdoell | last post by:
I have 5 cascading combo boxes on a form. Below is a sample of my vb in the first combo box: Private Sub CboDivision_AfterUpdate() 'When the Division is selected, the appropriate Segment...
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...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
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:
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
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
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?
1
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 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.