Access grouped optionbuttons by index
Hi,
I have question concerning some basic programming techniques:
In VB4 it was possible to label optionsbuttons, which belong to the same
group or frame, with the same name and then access these grouped optionsbuttons
by optionbuttonname(index).
So it was possible to avoid writing many IF statements.
This is not possible anymore, at least I get an error when assigning the
same name to two optionbuttons.
I want to use this technique in VBA for Powerpoint which is based on VB6,
I think.
Is there a similar possibility in VB6/VBA?
Thanks
Jürgen Schoch
Re: Access grouped optionbuttons by index
Not 100% certain what the equivalent terminology is in Powerpoint, but in
Access you'd name your buttons optButton1, optButton2 and so on. Then you
can refer to them as Me.Controls("optButton" & intLoop)
--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
"Jürgen Schoch" <schoch@gsf.de> wrote in message
news:3dda1e08$1@tnews.web.devx.com...
>
> Hi,
> I have question concerning some basic programming techniques:
> In VB4 it was possible to label optionsbuttons, which belong to the same
> group or frame, with the same name and then access these grouped
optionsbuttons
> by optionbuttonname(index).
> So it was possible to avoid writing many IF statements.
> This is not possible anymore, at least I get an error when assigning the
> same name to two optionbuttons.
>
> I want to use this technique in VBA for Powerpoint which is based on VB6,
> I think.
> Is there a similar possibility in VB6/VBA?
>
> Thanks
>
> Jürgen Schoch
Re: Access grouped optionbuttons by index
In Powerpoint 2000 it works exactly as you wrote.
Thanks a lot for your help
Jürgen
"Douglas J. Steele" <djsteele@canada.com> wrote:
>Not 100% certain what the equivalent terminology is in Powerpoint, but in
>Access you'd name your buttons optButton1, optButton2 and so on. Then you
>can refer to them as Me.Controls("optButton" & intLoop)
>
>--
>Doug Steele, Microsoft Access MVP
>http://I.Am/DougSteele
>
>
>"Jürgen Schoch" <schoch@gsf.de> wrote in message
>news:3dda1e08$1@tnews.web.devx.com...
>>
>> Hi,
>> I have question concerning some basic programming techniques:
>> In VB4 it was possible to label optionsbuttons, which belong to the same
>> group or frame, with the same name and then access these grouped
>optionsbuttons
>> by optionbuttonname(index).
>> So it was possible to avoid writing many IF statements.
>> This is not possible anymore, at least I get an error when assigning the
>> same name to two optionbuttons.
>>
>> I want to use this technique in VBA for Powerpoint which is based on VB6,
>> I think.
>> Is there a similar possibility in VB6/VBA?
>>
>> Thanks
>>
>> Jürgen Schoch
>
>