Variables in Macros?

J

JasonSelf

If I have gone to the Macros Object area in Access and I set up a bunc
of TransferSpreadsheet Actions, is there a way I can assign variable
that I can change with a form for things like location of th
Spreadsheet I am pulling in and the name of the Table I am pulling to?
I have not found how I could get a more advanced edit abilitiy withi
the macro actions...any help would be appreciated.

Thank you,
Jason Sel
 
S

Steve Schapel

Jason,

For the File Name argument, you can refer to the value of a control on a
form, using syntax such as...
=[Forms]![NameOfForm]![NameOfControl]
I am not 100% sure about this, and can't check it right now, but I don't
think this type of approach is possible with the Table Name argument.
In any case, it is generally a good idea to import to a temporary table
with TransferSpreadsheet, and then use an Append Query or Make-Table
Query from there to the data's final resting place, so maybe that might
help.
 

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

Top