Solved

How to group common properties ?

Posted on 1998-09-12
3
127 Views
Last Modified: 2010-04-30
Hi.
I'm trying to change in "execution time" the Datachange property of 10 textbox. I use a button to validate a new record of these 10 textbox but I need use the same button if I want to modify one of the records that I have done. Cause I put in the code of the button the Addnew..and Update, I want to identify when a textbox change its data (by datachange) and then in the code of this button I can to reconogize the change and I can substitute the Addnew by an Edit..Update. My problem is that I have to write the whole property datachane of the 10 textbox and if any of these changes, then use the modify option of the button and not the "addnew option". How can I simplify the code? Can I to group the Datachange property of the whole textbox
0
Comment
Question by:netkuk
[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:wj7ster
ID: 1434472
Can you say that again?  It is not very clear what you try to achieve.

Thank you.
0
 
LVL 12

Accepted Solution

by:
mark2150 earned 50 total points
ID: 1434474
Make a control array out of your text boxes. Then when the event fires you'll get an INDEX value that tells you which of the controls had the event. Your code can then use the index for whatever. This allows one event sequence instead of 10.

M

0
 

Author Comment

by:netkuk
ID: 1434475
that solves my problem but I have to give the same name (in an array) in all the textbox and I have to control myself a maskedbox that I can't join with the array. Thank you anyway mark2150
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
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…
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…

729 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