Execute DOS commands in VBA code

B

bill_morgan

Is there a simple VBA command similar to xp_cmdshell for T-SQL that will
allow me to execute a DOS command (e.g. MOVE, etc.) through VBA code - a
command that works for DOS like RunSQL works for SQL?

Thanks for your help ...

Bill Morgan
 
D

Douglas J Steele

As Alex points out, the Shell command lets you run external commands.

However, if you're trying to move files from one location to another, the
VBA Name statement lets you move a file from one folder to another.
 

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