GET DATA loop through folder

#1
Hi
I need to run the same syntax over some files. They are in the folder named DBase.
I mean, there is a db01.sav and over it run the syntax, then do the same for db02.sav and so on. How do i make it? How run the process only listing one time the files i'm interested?
Thanks for your time and interest.
 
#2
I'm very lost. I did this
Code:
GET
   FILE='C:\Users\***\Bases\Base.sav'.
DATASET NAME Conjunto_de_datos9 WINDOW=FRONT.

ADD FILES /FILE=*
  /FILE='\\YYY\Bases_\Base_2001.sav'.
EXECUTE

ADD FILES /FILE=*
  /FILE='\\YYY\Bases_\Base_2002.sav'.
EXECUTE

ADD FILES /FILE=*
  /FILE='\\YYY\Bases_\Base_2003.sav'.
EXECUTE

ADD FILES /FILE=*
  /FILE='\\YYY\Bases_\Base_2004.sav'.
EXECUTE

And so on until year 2012.
Then, i need ti run this crosstab
Code:
CROSSTABS
  /TABLES=VAR1 BY VAR2
  /FORMAT=AVALUE TABLES
  /CELLS=COUNT
  /COUNT ROUND CELL.
Doing that for all databases is impossible for me. I tried the ADD FILE, but there is some differences in the text defining every variable, so itsn't working well. The big issue is that i don't know how to declare the databses in a macro and run the same command or syntax for each one. Thanks for your comments.