Date: Mon, 10 Nov 2008 17:17:25 +0800
Reply-To: Thien Hop <thienhop@gmail.com>
Sender: "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From: Thien Hop <thienhop@gmail.com>
Subject: Re: Automatically searching & deleting sps
Content-Type: text/plain; format=flowed; charset="iso-8859-1";
reply-type=original
Dear Jon & Kendall,
Thank you very much for your advices.
Since I've never used Python before so it seems to be a big challenge for me
to write a correct script. May I bother you with it when you have some time
to share.
Knowing that it is dangerrous to use the automatic deleting, I may use it
for cleaning other files type ie. temp or unwanted types
In addition, please advise what SPSS syntax/ script can be used to get any
other file (not SPSS) to run/ open ie. Excel file, PP.
Thank you very much,
Hop
----- Original Message -----
From: "Peck, Jon" <peck@spss.com>
To: "Thien Hop" <thienhop@gmail.com>; <SPSSX-L@LISTSERV.UGA.EDU>
Sent: Sunday, November 09, 2008 10:43 PM
Subject: RE: Re: [SPSSX-L] Automatically searching & deleting sps
This is easy to do with programmability. I don't have time to spell this
out right now (on the way to the airport), but you can use
Python os.walk to iterate over all files on your system.
Use fnmatch.fnmatch to test the file name against the pattern you want
Use os.remove to delete a file that passes the test.
BE CAREFUL with this, or you could wind up with a lot of extra free space on
your disk!
HTH,
Jon Peck
-----Original Message-----
From: SPSSX(r) Discussion [mailto:SPSSX-L@LISTSERV.UGA.EDU] On Behalf Of
Thien Hop
Sent: Sunday, November 09, 2008 2:58 AM
To: SPSSX-L@LISTSERV.UGA.EDU
Subject: Re: [SPSSX-L] Automatically searching & deleting sps
Dear Manoj Soni,
Sorry I did not make myself clear enough. Actually I want to write a script
in SPSS that can do the job of searching & deleting specific file type i.e
**.sps anywhere even in Recycle bin.
Thanks once again!
Hop
----- Original Message -----
From: <manoj@iihmr.org>
To: "Tran Robert" <thienhop@gmail.com>
Cc: <SPSSX-L@LISTSERV.UGA.EDU>
Sent: Sunday, November 09, 2008 1:18 PM
Subject: Re: Automatically searching & deleting sps
> Dear
>
> you just have to put a search in computer
>
> Search Name = *.sps
>
> Location = C:/D; or more
>
> this will help
>
>
> Manoj Soni
> Assistant Data Analyst
> INSTITUTE OF HEALTH MANAGEMENT RESEARCH
> 1, P.D. Marg, Near Sanganer Airport,
> Jaipur. 302001. Rajasthan. INDIA.
> Phone : 91-0141-2791431-34
> Fax : 91-0141-2792138
> manoj@iihmr.org
>
> ----- Original Message -----
> From: "Tran Robert" <thienhop@gmail.com>
> To: <SPSSX-L@LISTSERV.UGA.EDU>
> Sent: Saturday, November 08, 2008 9:10 PM
> Subject: Automatically searching & deleting sps
>
>
>> Dear all,
>>
>> May I know if there is a way to automatically search & delete files.sps
>> in a
>> drive .ie anywhere in the C drive or D drive.
>>
>> Any advice is highly appreciated!
>>
>> Thanks a lot,
>>
>> Hop
>>
>> =====================
>> To manage your subscription to SPSSX-L, send a message to
>> LISTSERV@LISTSERV.UGA.EDU (not to SPSSX-L), with no body text except the
>> command. To leave the list, send the command
>> SIGNOFF SPSSX-L
>> For a list of commands to manage subscriptions, send the command
>> INFO REFCARD
>>
>
>
=====================
To manage your subscription to SPSSX-L, send a message to
LISTSERV@LISTSERV.UGA.EDU (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD
=====================
To manage your subscription to SPSSX-L, send a message to
LISTSERV@LISTSERV.UGA.EDU (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD