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

How to get properties of option button?

Access 2000

How can I get the properties of the selected option button within an option
group?

With the code below it returns the 'HelpcontextID) of the option group, and
not the ID associated with the selected button.

Me.ActiveControl.Properties("HelpcontextId")

Thanks for any help.

Adrian
Nov 12 '05 #1
6 2854
Since you are using ActiveControl, I'm guessing that this is a generic piece
of code that gets called when the user presses F1. If that is the case, it
would probably be a lot easier to just include all of the options in that
help page or have the option group call a page with links that take you to
each of the options.

--
Wayne Morgan
MS Access MVP
"Adrian" <no****@hotmail.com> wrote in message
news:bv*******************@news.demon.co.uk...
Access 2000

How can I get the properties of the selected option button within an option group?

With the code below it returns the 'HelpcontextID) of the option group, and not the ID associated with the selected button.

Me.ActiveControl.Properties("HelpcontextId")

Thanks for any help.

Adrian

Nov 12 '05 #2
Wayne,

Thanks for your reply.
have the option group call a page with links

That was my fallback strategy! But I had hoped it would not be too difficult
to take the user directly to the correct help page.

Adrian.

"Wayne Morgan" <co***************************@hotmail.com> wrote in message
news:My******************@newssvr23.news.prodigy.c om... Since you are using ActiveControl, I'm guessing that this is a generic piece of code that gets called when the user presses F1. If that is the case, it
would probably be a lot easier to just include all of the options in that
help page or have the option group call a page with links that take you to
each of the options.

--
Wayne Morgan
MS Access MVP
"Adrian" <no****@hotmail.com> wrote in message
news:bv*******************@news.demon.co.uk...
Access 2000

How can I get the properties of the selected option button within an

option
group?

With the code below it returns the 'HelpcontextID) of the option group,

and
not the ID associated with the selected button.

Me.ActiveControl.Properties("HelpcontextId")

Thanks for any help.

Adrian


Nov 12 '05 #3
On Tue, 27 Jan 2004 12:17:02 -0000, Adrian wrote:

Try using the following in the AfterUpdate event of the OptionGroup. Not
entirely simple, but not all that complicated either. Remember to change
the control names to what you are using.

Dim cntrl As Control
For Each cntrl In Me!OptionGroup.Controls
If cntrl.ControlType = ac(OptionButtonType) Then
If cntrl.OptionValue = Me!OptionGroup Then
Me!OptionGroup.HelpContextId = cntrl.HelpContextId
End If
End If
Next cntrl

--
Mike Storr
veraccess.com

Wayne,

Thanks for your reply.
have the option group call a page with links

That was my fallback strategy! But I had hoped it would not be too

difficult to take the user directly to the correct help page.

Adrian.


Nov 12 '05 #4
Mike,

Thanks very much. That works very nicely.

Any ideas of how to pass the helpcontextid for a tab (page) to the
helpcontextid for the form? I cannot find an event that fires when the
active tab changes.

Thanks again.

Adrian

"Mike Storr" <st******@sympatico.ca> wrote in message
news:1b******************************@40tude.net.. .
On Tue, 27 Jan 2004 12:17:02 -0000, Adrian wrote:

Try using the following in the AfterUpdate event of the OptionGroup. Not
entirely simple, but not all that complicated either. Remember to change
the control names to what you are using.

Dim cntrl As Control
For Each cntrl In Me!OptionGroup.Controls
If cntrl.ControlType = ac(OptionButtonType) Then
If cntrl.OptionValue = Me!OptionGroup Then
Me!OptionGroup.HelpContextId = cntrl.HelpContextId
End If
End If
Next cntrl

--
Mike Storr
veraccess.com

Wayne,

Thanks for your reply.
have the option group call a page with links


That was my fallback strategy! But I had hoped it would not be too

difficult
to take the user directly to the correct help page.

Adrian.


Nov 12 '05 #5
On Wed, 28 Jan 2004 10:47:35 GMT, Adrian wrote:

It depends on what triggers the move to a new page. The Click event applies
to each page in the tabcontrol, so you could use it to set
Me.HelpContextID = Me!TabControl.Pages("PageName").HelpContextID.
The OnChange event of the tabcontrol itself fires when the focus moves to a
different page. You can also use the Value property of the tabcontrol -
which is the selected page.
--
Mike Storr
veraccess.com

Mike,

Thanks very much. That works very nicely.

Any ideas of how to pass the helpcontextid for a tab (page) to the
helpcontextid for the form? I cannot find an event that fires when the
active tab changes.

Thanks again.

Adrian

"Mike Storr" <st******@sympatico.ca> wrote in message
news:1b******************************@40tude.net.. .
On Tue, 27 Jan 2004 12:17:02 -0000, Adrian wrote:

Try using the following in the AfterUpdate event of the OptionGroup. Not
entirely simple, but not all that complicated either. Remember to change
the control names to what you are using.

Dim cntrl As Control
For Each cntrl In Me!OptionGroup.Controls
If cntrl.ControlType = ac(OptionButtonType) Then
If cntrl.OptionValue = Me!OptionGroup Then
Me!OptionGroup.HelpContextId = cntrl.HelpContextId
End If
End If
Next cntrl

--
Mike Storr
veraccess.com

Wayne,

Thanks for your reply.

> have the option group call a page with links

That was my fallback strategy! But I had hoped it would not be too

difficult
to take the user directly to the correct help page.

Adrian.


Nov 12 '05 #6
Mike,

Thanks for your help. That has given me some ideas to have a look at.

Adrian

"Mike Storr" <st******@sympatico.ca> wrote in message
news:1m*****************************@40tude.net...
On Wed, 28 Jan 2004 10:47:35 GMT, Adrian wrote:

It depends on what triggers the move to a new page. The Click event applies to each page in the tabcontrol, so you could use it to set
Me.HelpContextID = Me!TabControl.Pages("PageName").HelpContextID.
The OnChange event of the tabcontrol itself fires when the focus moves to a different page. You can also use the Value property of the tabcontrol -
which is the selected page.
--
Mike Storr
veraccess.com

Mike,

Thanks very much. That works very nicely.

Any ideas of how to pass the helpcontextid for a tab (page) to the
helpcontextid for the form? I cannot find an event that fires when the
active tab changes.

Thanks again.

Adrian

"Mike Storr" <st******@sympatico.ca> wrote in message
news:1b******************************@40tude.net.. .
On Tue, 27 Jan 2004 12:17:02 -0000, Adrian wrote:

Try using the following in the AfterUpdate event of the OptionGroup. Not entirely simple, but not all that complicated either. Remember to change the control names to what you are using.

Dim cntrl As Control
For Each cntrl In Me!OptionGroup.Controls
If cntrl.ControlType = ac(OptionButtonType) Then
If cntrl.OptionValue = Me!OptionGroup Then
Me!OptionGroup.HelpContextId = cntrl.HelpContextId
End If
End If
Next cntrl

--
Mike Storr
veraccess.com
Wayne,

Thanks for your reply.

>> have the option group call a page with links

That was my fallback strategy! But I had hoped it would not be too
difficult
to take the user directly to the correct help page.

Adrian.


Nov 12 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Michael Winter | last post by:
Below is the IDL definition of the HTMLOptionElement. interface HTMLOptionElement : HTMLElement { readonly attribute HTMLFormElement form; attribute boolean defaultSelected;...
6
by: Luke Dalessandro | last post by:
I'm not sure if this is the correct forum for platform specific (Mozilla/Firefox) javascript problems, so just shout and point me to the correct newsgroup if I'm being bad. Here's the deal... ...
3
by: davidkarlsson74 | last post by:
Error: document.getElementById("folderMenu").cells has no properties File: http://www.volkswagen.se/tillbehor/js/foldermenu.js Rad: 49 The function activates different DIV:s, but doesn't seem to...
24
by: downwitch | last post by:
Hi, I know this has been covered here and in the .public groups, but it seems like it's been a while, especially around here, so I just thought I'd ask again to see if anyone has figured out a...
0
by: enantiomer | last post by:
Having a problem with visual studio 2005 doing ASP.net. when in source mode (i.e. looking at the html directly), in the properties toolbar is an option called "DOCUMENT". It has some basic...
1
by: =?Utf-8?B?aXd1Y29tcHV0ZXJnZWVrMDU=?= | last post by:
I have encountered a frustrating problem with the VB environment, and I am afraid I need to re-install it on my system. I would like to know whether any of you have encountered the same problem or...
1
by: sunnyluthra1 | last post by:
Hi Everyone, I am working on a piece of code, that displays the properties(Name, Datatype, size & Description) of the table in the database. Now I want to further Enhance the code. I Have created...
4
by: 2levelsabove | last post by:
<form method="post" action="javascript:void(0);" name="ShareOptionsForm" onsubmit="if (VerifyForm('ShareOptionsForm')) { AddShareJob(); HideShareOptions(); setTimeout('RefreshCart()', 1000); } else {...
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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...
0
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...
0
Oralloy
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,...

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.