Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dymnamic option group or grouping in a form?

Status
Not open for further replies.

dandot

Programmer
Jul 19, 2005
53
CA
Hi All,

Can any of you PLEASE help me with this problem?

I have the following 2 tables in sql server:

CREATE Table dbo.RiskCode(
RiskCodeID INT IDENTITY NOT NULL,
Risk_Type int NOT NULL,
Risk_Code varchar(25) NOT Null,
Sort_Order int NULL)


CREATE Table dbo.NIRAVersion(
NIRAVersionID INT IDENTITY NOT NULL,
NIRA_Version_Name datetime NOT NULL,
RiskCodeID int NOT Null,
Active bit NOt NULL )



I would like to create a form(checklist) to allow the user to input data into the NIRAVersion table.

The form will have a textbox to enter the NIRA_Version_Name and then a list of all riskcodes with a checkbox (possible subform) next to item (Active in NIRAVersion).

The problem I have is that the users would like the list of riskcodes to be grouped by risktype.

So like this


RiskType1
RiskCode 1 (checkbox)
Riskcode 3 (checkbox)

RiskType2
RiskCode 8 (checkbox)
Riskcode 9 (checkbox)

etc...


however the numer of risktypes is dynamic as they can add more at any time.

So I can't do this with subforms as there is not a fixed number of risktypes for me to create an x amount of forms.

I thought about doing this with option groups, however I dont' believe there is a way to have a dynamic list of options for option groups.

Is there a way i could have a dymaic list of options for option groups?



 
As an update i think i will decide to this with a combo box.
 
Yes, this sounds like a job for cascading comboboxes (or listboxes).

Ken S.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top