How do I create a macro to type repetitive entries?

H

halok

When I am entering data in a database there are many times I have to type the
same entry, such as a city or zip code. How do I create a macro to do that?
 
K

KARL DEWEY

On your data entry form put two unbound text boxes and a command button.
Have command button call marco that has action Set Value to place the value
of text box in the city and zip code fields.
 
H

halok

I cannot find an acton "Set Value" or SetValue" in the macro actions. I am
new at this and need descriptive help.
 
P

Pete D.

You failed to mention your version of access. Set value will not be visable
in 2007 if you don't select the ribbon bar icon for show all actions.
 
T

tina

well, first of all, to call a macro, you have to be entering data via a
form, not directly into a table.

if it's always the same city and zip, you can set the Default value of the
form controls (bound to the city and zip fields) to the appropriate values;
they'll be entered automatically each time a new record is added using that
form, but the Default Value will have no effect if you change data in an
existing record.

if it's NOT always the same city and zip, you'll need to set Conditions in
the macro to assign the correct city and zip according to some criteria that
the macro has access to read; see Pete D.'s post regarding A2007 re the
SetValue action. or see Jeff Boyce's suggestion regarding the use of
combobox controls on the form, instead of using a macro.

hth


halok said:
When I am entering data in a database there are many times I have to type the
same entry, such as a city or zip code. How do I create a macro to do
that?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top