Command Button for Tables?

R

Rose

I know how to write a command button in a form to open a query. Is there a
way to open a table.
 
F

fredg

I know how to write a command button in a form to open a query. Is there a
way to open a table.

Yes there is, but why would you want anyone to look at a table.
Tables are for data storage, not display.

DoCmd.OpenTable "TableName", , acReadOnly


will open the named table as read only.
See VBA help for the other arguments available.
 
R

Rose

Thank you both for your comments, it worked. Fred I wanted to have someone
able to add items into a drop down field. I usually would not have people in
the tables. Thanks for your words of caution.
 
K

KARL DEWEY

You might want to heed the horror stories of dropdowns in tables and use a
dropdown in the data entry form instead.
 
Top