?
Solved

control with index!?

Posted on 2003-03-18
3
Medium Priority
?
122 Views
Last Modified: 2011-09-20
Hello experienced developer!

I have problem that makes me crazy.

If I have control (checkbox1) on form, I can read state by
me.controls("checkbox1").value

But how to do it if control has index - like checkbox1(0) ??
me.controls("checkbox1(0)").value
somehow does not work.

I can't use simply checkbox1(0).value, because all control names are in DB and i use next procedure to save state of controls:

me.controls(my_recordset!ctrl_name).value

where my_recordset!ctrl_name are names of controls on form (checkbox1, checkbox2, text1,text2)

It was all OK until number of controls didn't reach 255. Now I am forced to use indexes and now
me.controls(my_recordset!ctrl_name).value
become useless. Or not?

Can anyone help me?

Thank you!

Mitja
0
Comment
Question by:mitja040500
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 2

Expert Comment

by:Jacamar
ID: 8161316
Me.Checkbox1(0).Value
0
 
LVL 28

Accepted Solution

by:
AzraSound earned 1000 total points
ID: 8161334
Me.Controls("Check1")(0).Value = vbChecked
0
 

Author Comment

by:mitja040500
ID: 8161502
Thank You!

You saved me at least one sleeples night!

Mitja
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
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 utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month14 days, 20 hours left to enroll

770 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