Solved

option boxes EASY

Posted on 2002-05-14
2
124 Views
Last Modified: 2010-05-02
i have about 3 frames on one sstab screen, in each frame is about 4 option boxes.
for example
O =  Op1
0 =  Op2
0 =  Op3
0 =  Op4

as there is nothing similar except for the text, i will be doing this to put the result in the database:Private

Sub Option1_Click()
If Option1.Value = True Then
Text1.Text = "Op1"
End If
End Sub
----------the same method for each option---------

so on the update to the dbase i will use text1.text value, is this the best method??

B
0
Comment
Question by:bolox
2 Comments
 
LVL 49

Accepted Solution

by:
Ryan Chong earned 50 total points
Comment Utility
Hi,

You can declare/ create the Option boxes as a Control Array, then you can check which Option button is checked by using this:

Private Sub Option1_Click(Index As Integer)
    Text1.Text = Option1(Index).Caption 'Or = "Opt" & Index + 1
End Sub

Do as similar for other frames

Hope this help
0
 
LVL 1

Author Comment

by:bolox
Comment Utility
Thats it!!! an array, i forgot about that.

thanx
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now