A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Main form and subform



 
 
Thread Tools Display Modes
  #1  
Old April 11th, 2009, 05:10 PM posted to microsoft.public.access.tablesdbdesign
Beeyen
external usenet poster
 
Posts: 100
Default Main form and subform

Good Day,

Let me try this one again; I have a master form with several Tabs and
Subforms. In the master form there is a field called Work Category (a combo
box) and in this field, among other listings I have rate, plans, co-pay and
accumulations. In one of my Tabs called Routing, one of my fields is called
Claims Monitoring

If rate, plans, co-pay or accumulation is selection in the Work Category
field of the Master form I would like to see the Claim Monitoring field
populated with which every the selection is, otherwise the field is
grayed-out.

Can this be done?

Thanks in advance


  #2  
Old April 11th, 2009, 10:12 PM posted to microsoft.public.access.tablesdbdesign
Steve[_70_]
external usenet poster
 
Posts: 152
Default Main form and subform

I will assume that your Work Category combobox is based on a table that
looks like:
TblWorkCategory
WorkCategoryID
WorkCategory
and your combobox has its Bound Column property set to 1 and Column Width
property set to 0;1.5.

To do what you want ...........
1. Go to design view and set the Enabled property of Claim Monitoring
field to False
2. Put the following code in the AfterUpdate event of your combobox:
Select Case Me![Work Category].Column(2)
Case "Rate" Or "Plans" Or "Co-pay" Or "Accumulation"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

Steve



"Beeyen" wrote in message
...
Good Day,

Let me try this one again; I have a master form with several Tabs and
Subforms. In the master form there is a field called Work Category (a
combo
box) and in this field, among other listings I have rate, plans, co-pay
and
accumulations. In one of my Tabs called Routing, one of my fields is
called
Claims Monitoring

If rate, plans, co-pay or accumulation is selection in the Work Category
field of the Master form I would like to see the Claim Monitoring field
populated with which every the selection is, otherwise the field is
grayed-out.

Can this be done?

Thanks in advance




  #3  
Old April 12th, 2009, 08:13 AM posted to microsoft.public.access.tablesdbdesign
Beeyen
external usenet poster
 
Posts: 100
Default Main form and subform

Good Day Steve,

Thank you for the assistance. You are correct with the parameters of the
combo box and I have entered the code as you suggested (as is below):

Private Sub Work_Category_AfterUpdate()
Select Case Me![Work Category].Column(2)
Case "rates" Or "plans" Or "co-pay" Or "accumulations"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

End Sub

Yet, I received a debugging runtime error 13, type mismatch message, which
stops at: Case "rates" Or "plans" Or "co-pay" Or "accumulations"

Any ideas?

"Steve" wrote:

I will assume that your Work Category combobox is based on a table that
looks like:
TblWorkCategory
WorkCategoryID
WorkCategory
and your combobox has its Bound Column property set to 1 and Column Width
property set to 0;1.5.

To do what you want ...........
1. Go to design view and set the Enabled property of Claim Monitoring
field to False
2. Put the following code in the AfterUpdate event of your combobox:
Select Case Me![Work Category].Column(2)
Case "Rate" Or "Plans" Or "Co-pay" Or "Accumulation"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

Steve



"Beeyen" wrote in message
...
Good Day,

Let me try this one again; I have a master form with several Tabs and
Subforms. In the master form there is a field called Work Category (a
combo
box) and in this field, among other listings I have rate, plans, co-pay
and
accumulations. In one of my Tabs called Routing, one of my fields is
called
Claims Monitoring

If rate, plans, co-pay or accumulation is selection in the Work Category
field of the Master form I would like to see the Claim Monitoring field
populated with which every the selection is, otherwise the field is
grayed-out.

Can this be done?

Thanks in advance





  #4  
Old April 12th, 2009, 02:03 PM posted to microsoft.public.access.tablesdbdesign
John... Visio MVP
external usenet poster
 
Posts: 900
Default Main form and subform

Two suggestions
1: replace the "or"s with commas so that the line is
Case "rates", "plans", "co-pay", "accumulations"
2: Avoid any offers by steve to help. He is a known troll who offers
questionable services for questionable fees

John... Visio MVP

"Beeyen" wrote in message
...
Good Day Steve,

Thank you for the assistance. You are correct with the parameters of the
combo box and I have entered the code as you suggested (as is below):

Private Sub Work_Category_AfterUpdate()
Select Case Me![Work Category].Column(2)
Case "rates" Or "plans" Or "co-pay" Or "accumulations"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

End Sub

Yet, I received a debugging runtime error 13, type mismatch message, which
stops at: Case "rates" Or "plans" Or "co-pay" Or "accumulations"

Any ideas?

"Steve" wrote:

I will assume that your Work Category combobox is based on a table that
looks like:
TblWorkCategory
WorkCategoryID
WorkCategory
and your combobox has its Bound Column property set to 1 and Column Width
property set to 0;1.5.

To do what you want ...........
1. Go to design view and set the Enabled property of Claim Monitoring
field to False
2. Put the following code in the AfterUpdate event of your combobox:
Select Case Me![Work Category].Column(2)
Case "Rate" Or "Plans" Or "Co-pay" Or "Accumulation"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

Steve



"Beeyen" wrote in message
...
Good Day,

Let me try this one again; I have a master form with several Tabs and
Subforms. In the master form there is a field called Work Category (a
combo
box) and in this field, among other listings I have rate, plans, co-pay
and
accumulations. In one of my Tabs called Routing, one of my fields is
called
Claims Monitoring

If rate, plans, co-pay or accumulation is selection in the Work
Category
field of the Master form I would like to see the Claim Monitoring field
populated with which every the selection is, otherwise the field is
grayed-out.

Can this be done?

Thanks in advance







  #5  
Old April 12th, 2009, 03:02 PM posted to microsoft.public.access.tablesdbdesign
Beeyen
external usenet poster
 
Posts: 100
Default Main form and subform

Good Day John,

Thanks for the heads up. I am an Access medium beginner (self – taught) and
am working on a database with a number of conditions and I have lots of
questions. So it has been good to seek the assistance of the community. I
was thinking to myself with so much more corruption (mostly due to the
current economy) it is good to be able to raise a question and have so many
united for an answer. My second job is building computers; I do it for the
experience. I have always shared my knowledge and assistance daily; in return
knowing others are not being taken advantage of and can enjoy the technology
before them.

Thanks again

"John... Visio MVP" wrote:

Two suggestions
1: replace the "or"s with commas so that the line is
Case "rates", "plans", "co-pay", "accumulations"
2: Avoid any offers by steve to help. He is a known troll who offers
questionable services for questionable fees

John... Visio MVP

"Beeyen" wrote in message
...
Good Day Steve,

Thank you for the assistance. You are correct with the parameters of the
combo box and I have entered the code as you suggested (as is below):

Private Sub Work_Category_AfterUpdate()
Select Case Me![Work Category].Column(2)
Case "rates" Or "plans" Or "co-pay" Or "accumulations"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

End Sub

Yet, I received a debugging runtime error 13, type mismatch message, which
stops at: Case "rates" Or "plans" Or "co-pay" Or "accumulations"

Any ideas?

"Steve" wrote:

I will assume that your Work Category combobox is based on a table that
looks like:
TblWorkCategory
WorkCategoryID
WorkCategory
and your combobox has its Bound Column property set to 1 and Column Width
property set to 0;1.5.

To do what you want ...........
1. Go to design view and set the Enabled property of Claim Monitoring
field to False
2. Put the following code in the AfterUpdate event of your combobox:
Select Case Me![Work Category].Column(2)
Case "Rate" Or "Plans" Or "Co-pay" Or "Accumulation"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

Steve



"Beeyen" wrote in message
...
Good Day,

Let me try this one again; I have a master form with several Tabs and
Subforms. In the master form there is a field called Work Category (a
combo
box) and in this field, among other listings I have rate, plans, co-pay
and
accumulations. In one of my Tabs called Routing, one of my fields is
called
Claims Monitoring

If rate, plans, co-pay or accumulation is selection in the Work
Category
field of the Master form I would like to see the Claim Monitoring field
populated with which every the selection is, otherwise the field is
grayed-out.

Can this be done?

Thanks in advance








  #6  
Old April 12th, 2009, 05:21 PM posted to microsoft.public.access.tablesdbdesign
Beeyen
external usenet poster
 
Posts: 100
Default Main form and subform

Good Day John
Thanks for the assistance, the commas worked. Now I received another
Run-time 2465, The mainform can't find the field 'Claims Monitoring' referred
to in your expression.

Could it be that the coding does not reference that the 'Claims Monitoring'
field located in a Tab Subform called Routing?

rivate Sub WorkCategory_AfterUpdate()
Select Case Me![WorkCategory].Column(2)
Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False

"Beeyen" wrote:

Good Day John,

Thanks for the heads up. I am an Access medium beginner (self – taught) and
am working on a database with a number of conditions and I have lots of
questions. So it has been good to seek the assistance of the community. I
was thinking to myself with so much more corruption (mostly due to the
current economy) it is good to be able to raise a question and have so many
united for an answer. My second job is building computers; I do it for the
experience. I have always shared my knowledge and assistance daily; in return
knowing others are not being taken advantage of and can enjoy the technology
before them.

Thanks again

"John... Visio MVP" wrote:

Two suggestions
1: replace the "or"s with commas so that the line is
Case "rates", "plans", "co-pay", "accumulations"
2: Avoid any offers by steve to help. He is a known troll who offers
questionable services for questionable fees

John... Visio MVP

"Beeyen" wrote in message
...
Good Day Steve,

Thank you for the assistance. You are correct with the parameters of the
combo box and I have entered the code as you suggested (as is below):

Private Sub Work_Category_AfterUpdate()
Select Case Me![Work Category].Column(2)
Case "rates" Or "plans" Or "co-pay" Or "accumulations"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

End Sub

Yet, I received a debugging runtime error 13, type mismatch message, which
stops at: Case "rates" Or "plans" Or "co-pay" Or "accumulations"

Any ideas?

"Steve" wrote:

I will assume that your Work Category combobox is based on a table that
looks like:
TblWorkCategory
WorkCategoryID
WorkCategory
and your combobox has its Bound Column property set to 1 and Column Width
property set to 0;1.5.

To do what you want ...........
1. Go to design view and set the Enabled property of Claim Monitoring
field to False
2. Put the following code in the AfterUpdate event of your combobox:
Select Case Me![Work Category].Column(2)
Case "Rate" Or "Plans" Or "Co-pay" Or "Accumulation"
Me![Claims Monitoring].Enabled = True
Case Else
Me![Claims Monitoring].Enabled = False
End Select

Steve



"Beeyen" wrote in message
...
Good Day,

Let me try this one again; I have a master form with several Tabs and
Subforms. In the master form there is a field called Work Category (a
combo
box) and in this field, among other listings I have rate, plans, co-pay
and
accumulations. In one of my Tabs called Routing, one of my fields is
called
Claims Monitoring

If rate, plans, co-pay or accumulation is selection in the Work
Category
field of the Master form I would like to see the Claim Monitoring field
populated with which every the selection is, otherwise the field is
grayed-out.

Can this be done?

Thanks in advance








  #7  
Old April 12th, 2009, 09:36 PM posted to microsoft.public.access.tablesdbdesign
John W. Vinson
external usenet poster
 
Posts: 18,261
Default Main form and subform

On Sun, 12 Apr 2009 09:21:01 -0700, Beeyen
wrote:

Good Day John
Thanks for the assistance, the commas worked. Now I received another
Run-time 2465, The mainform can't find the field 'Claims Monitoring' referred
to in your expression.

Could it be that the coding does not reference that the 'Claims Monitoring'
field located in a Tab Subform called Routing?


Yes. A Subform is another form; Me! refers to the form on which the code
exists (the main form in this case). The syntax for referencing a subform is
peculiar: you need to use the name *of the Subform control* (which may be
different than the name of the Form object within that control). Try

Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me!Routing.Form![Claims Monitoring].Enabled = True
Case Else
Me!Routing.Form![Claims Monitoring].Enabled = False

This means "look in the Subform control on this form (Me) named Routing; look
at the Form object within that Subform control (Form!); find the control named
[Claims Monitoring] and enable/disable it.
--

John W. Vinson [MVP]
  #8  
Old April 12th, 2009, 10:40 PM posted to microsoft.public.access.tablesdbdesign
John... Visio MVP
external usenet poster
 
Posts: 900
Default Main form and subform

John, thanks for the assist.

John... Visio MVP
"John W. Vinson" wrote in message
...
On Sun, 12 Apr 2009 09:21:01 -0700, Beeyen

wrote:

Good Day John
Thanks for the assistance, the commas worked. Now I received another
Run-time 2465, The mainform can't find the field 'Claims Monitoring'
referred
to in your expression.

Could it be that the coding does not reference that the 'Claims
Monitoring'
field located in a Tab Subform called Routing?


Yes. A Subform is another form; Me! refers to the form on which the code
exists (the main form in this case). The syntax for referencing a subform
is
peculiar: you need to use the name *of the Subform control* (which may be
different than the name of the Form object within that control). Try

Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me!Routing.Form![Claims Monitoring].Enabled = True
Case Else
Me!Routing.Form![Claims Monitoring].Enabled = False

This means "look in the Subform control on this form (Me) named Routing;
look
at the Form object within that Subform control (Form!); find the control
named
[Claims Monitoring] and enable/disable it.
--

John W. Vinson [MVP]



  #9  
Old April 19th, 2009, 12:25 AM posted to microsoft.public.access.tablesdbdesign
Beeyen
external usenet poster
 
Posts: 100
Default Main form and subform

Good Day Gentlemen,

I have tried the solution below, which makes perfect sense, but I continue
to received a runtime error 438 (Object doesn't support this property or
method). The code is included below. Any thought of what I might be doing
wrong?

Mainform = frmWorkload Information Tracker
Mainform field = WorkCategory
Subform = frmRouting
Subform field = ClaimMonitoring

Private Sub WorkCategory_AfterUpdate()
Select Case Me.WorkCategory.Column(2)
Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me!frmRouting.Form![ClaimMonitoring].Enabled = True

Case Else
Me!frmRouting.Form![ClaimMonitoring].Enabled = False

End Select

End Sub

Thank you

"John... Visio MVP" wrote:

John, thanks for the assist.

John... Visio MVP
"John W. Vinson" wrote in message
...
On Sun, 12 Apr 2009 09:21:01 -0700, Beeyen

wrote:

Good Day John
Thanks for the assistance, the commas worked. Now I received another
Run-time 2465, The mainform can't find the field 'Claims Monitoring'
referred
to in your expression.

Could it be that the coding does not reference that the 'Claims
Monitoring'
field located in a Tab Subform called Routing?


Yes. A Subform is another form; Me! refers to the form on which the code
exists (the main form in this case). The syntax for referencing a subform
is
peculiar: you need to use the name *of the Subform control* (which may be
different than the name of the Form object within that control). Try

Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me!Routing.Form![Claims Monitoring].Enabled = True
Case Else
Me!Routing.Form![Claims Monitoring].Enabled = False

This means "look in the Subform control on this form (Me) named Routing;
look
at the Form object within that Subform control (Form!); find the control
named
[Claims Monitoring] and enable/disable it.
--

John W. Vinson [MVP]




  #10  
Old April 19th, 2009, 01:15 AM posted to microsoft.public.access.tablesdbdesign
tina
external usenet poster
 
Posts: 1,997
Default Main form and subform

did you verify the name of the subform control *within the mainform*? a
subform is a form that is "housed" or "contained" in a control inside of
another form. that "container" control is the subform control within the
mainform. in your code, you need to make sure you're referring to the name
of the container control - NOT the name of the subform form object as it
shows in the database window. to get the correct name: open the mainform in
Design view. within the mainform, click *once* on the subform to select it.
in the Properties box, click on the Other tab and look at the Name property.
that's the name of the subform control within the mainform. for example,
let's say the above steps showed the subform control name as ChildMonitor.
assuming that the code is running in the mainform, the reference would be

Me!ChildMonitor.Form!ClaimMonitoring.Enabled = True

hth


"Beeyen" wrote in message
...
Good Day Gentlemen,

I have tried the solution below, which makes perfect sense, but I continue
to received a runtime error 438 (Object doesn't support this property or
method). The code is included below. Any thought of what I might be

doing
wrong?

Mainform = frmWorkload Information Tracker
Mainform field = WorkCategory
Subform = frmRouting
Subform field = ClaimMonitoring

Private Sub WorkCategory_AfterUpdate()
Select Case Me.WorkCategory.Column(2)
Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me!frmRouting.Form![ClaimMonitoring].Enabled = True

Case Else
Me!frmRouting.Form![ClaimMonitoring].Enabled = False

End Select

End Sub

Thank you

"John... Visio MVP" wrote:

John, thanks for the assist.

John... Visio MVP
"John W. Vinson" wrote in message
...
On Sun, 12 Apr 2009 09:21:01 -0700, Beeyen

wrote:

Good Day John
Thanks for the assistance, the commas worked. Now I received another
Run-time 2465, The mainform can't find the field 'Claims Monitoring'
referred
to in your expression.

Could it be that the coding does not reference that the 'Claims
Monitoring'
field located in a Tab Subform called Routing?


Yes. A Subform is another form; Me! refers to the form on which the

code
exists (the main form in this case). The syntax for referencing a

subform
is
peculiar: you need to use the name *of the Subform control* (which may

be
different than the name of the Form object within that control). Try

Case "RATES", "PLANS", "CO-PAY", "ACCUMULATIONS"
Me!Routing.Form![Claims Monitoring].Enabled = True
Case Else
Me!Routing.Form![Claims Monitoring].Enabled = False

This means "look in the Subform control on this form (Me) named

Routing;
look
at the Form object within that Subform control (Form!); find the

control
named
[Claims Monitoring] and enable/disable it.
--

John W. Vinson [MVP]






 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:45 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.