list box to store

Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

Forum home » Delegate support and help forum » Microsoft Access VBA Training and help » LIST BOX TO STORE VALUES

LIST BOX TO STORE VALUES

resolvedResolved · Medium Priority · Version 2003

Joanne has attended:
Access VBA course

LIST BOX TO STORE VALUES

If I had to 2 list boxes, user selects from one box to another, is it possible to have these stored so can be used for later use? And wot would be the code?

RE: LIST BOX TO STORE VALUES

Hi Joanne

Thanks for your question

Can you clarify the following for me please.

Do you wish the values to be stored so that they can be used again during the existing procedure's lifetime, or do you wish the values to be stored up until the database is closed, or, finally do you wish the values to be stored permanently?

Thanks

Stephen

RE: LIST BOX TO STORE VALUES

Hi Stephen I would like the values to be stored permanently so that I can use them again.
My aim is to have a multi-choice list box where the user selects their choice and the selcted items will go into the opposite list box then the user can print a report BUT the values are STORED so that when the user wants to know what was chosen last time he can find out. I want to use this to book IN/OUT, so that is why I need the values to store so the user can check up on the status of the items.
Sorry that I do not explain myself very well..


RE: LIST BOX TO STORE VALUES

Hi Joanne

Thanks for the clarification

If they data is to be stored indefinitely you need to save the data in a table.

I would create a procedure that

1. Stores the conents of the combo boxes as variables
2. Opens the table as a DAO recordset
3. Adds a new record and sets field values equal to the contents of the variables

Hope this helps

Regards

Stephen

RE: LIST BOX TO STORE VALUES

Hi Stephen sorry I have not got back to you earlier been very busy. Can you give me an example?
I'm not sure your idea would work, there are loads of types that would be booked in and out (approx 200) would that mean I would need 200 differant tables?

Thanks Jo

Tue 29 Dec 2009: Automatically marked as resolved.

 

Training courses

 

Training information:

Welcome. Please choose your application (eg. Excel) and then post your question.

Our Microsoft Qualified trainers will then respond within 24 hours (working days).

Frequently Asked Questions
What does 'Resolved' mean?

Any suggestions, questions or comments? Please post in the Improve the forum thread.


 

Access tip:

Run with the total

Often when creating reports with lists of transactions it can be useful to have a column which totals the transactions as the report progresses.

Using the Sum function gives the total for the whole group, not a running total.



Access provides an easy method of achieving a running total.



Click on the text box containing the data you wish to contain the running total.
Select the Data tab
Click in the Running sum option
Click the down arrow to view three options

View all Access hints and tips


Server loaded in 0.08 secs.