Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / May 2008

Tip: Looking for answers? Try searching our database.

second Option group not recognized

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Molasses26 - 30 Apr 2008 21:33 GMT
I created a form with one option group on it and later added a second option
group but when I try to reference the options in the second group in VB code
it doesn't "see" them.  
Basically my form consists of a text box called KW
One option group called Metering with 4 choices
 Option11 = 1
 Option13 = 2
 Option15 = 3
 Option17 = 4
One option group called Service with 4 choices:
 Option22 = 5
 Option24 = 6
 Option26 = 7
On my KW field I want to write an AfterUpdate code that disables the
Option26 in the Service group if the value of KW is less than 20.
IF me.kw < 20 then
  me.option26.enable = false
else
  me.options6.enable = true
end if

When I am typing the code and I type me. I see the options from the first
group on the list but not the options from the second group.  What is my
malfunction here?

Thanks!
strive4peace - 01 May 2008 07:12 GMT
modify the value of the FRAME

'set option26
me.service_controlname = 7

btw, you really should give your controls meaningful names.  Access, of
course, has no idea what to call them, so it just names them like this:
option26.  I would do something like Service_something

where
'something' describes the option

OR, what I actually do is this:
Service_03
if it is the 3rd choice in a frame called Service ... but then I have
code that loops through the option choices and boldfaces the label of
the selected option so there is a logical REASON to use numbers in the
name <smile>

Warm Regards,
Crystal

Access Basics
8-part free tutorial that covers essentials in Access
http://www.accessmvp.com/Strive4Peace/Index.htm

 *
   (: have an awesome day :)
 *

> I created a form with one option group on it and later added a second option
> group but when I try to reference the options in the second group in VB code
[quoted text clipped - 22 lines]
>
> Thanks!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.