LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (December 2003)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Thu, 18 Dec 2003 11:24:15 -0000
Sender:   "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:   Stephen Hampshire <>
Subject:   Re: start and run syntax by xxx.bat file
Comments:   To: Max Bell <>
In-Reply-To:   <>
Content-Type:   text/plain; charset="iso-8859-1"

I normally use a vbscript file, which works much the same way.

You can just enter vb commands into a text file and save it with the extension .vbs.

The windows scripting host (if enabled) will run the script when you double-click it.

For example:

Set appSPSS = CreateObject("SPSS.Application")

Set SPSSdata = appSPSS.OpenDataDoc ("C:\Temp\DataTest\test.sav") strcomm = "SAVE TRANSLATE OUTFILE='C:\Temp\DataTest\test.dat'" strcomm = strcomm & " /TYPE=TAB /MAP /REPLACE."

appSPSS.ExecuteCommands strcomm, True

appSPSS.quit set SPSSdata = nothing set appSPSS = nothing

which just runs some syntax to export some data as a text file.



> dear listers, > > is it possible to start and run a syntax using a xxx.bat file? And > then automatically close SPSS? > > I have a bat-file test.bat : > > "c:\dir1\dir2\test.sps" > > and it offcourse only opens the syntax > > or should I use scripts or macro? > > > Max

Back to: Top of message | Previous page | Main SPSSX-L page