<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
     xmlns:admin="http://webns.net/mvcb/"
     xmlns:content="http://purl.org/rss/1.0/modules/content/"
     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
	<channel> 

	<title>Comments on: How to export data in folders?</title>
	<link>http://ask.metafilter.com/27572/How-to-export-data-in-folders/</link>
	<description>Comments on Ask MetaFilter post How to export data in folders?</description>
	<pubDate>Sun, 20 Nov 2005 09:29:44 -0800</pubDate>
	<lastBuildDate>Sun, 20 Nov 2005 09:29:44 -0800</lastBuildDate>
	<language>en-us</language>
	<docs>http://blogs.law.harvard.edu/tech/rss</docs>
	<ttl>60</ttl>

	<item>
		<title>Question: How to export data in folders?</title>
		<link>http://ask.metafilter.com/27572/How-to-export-data-in-folders</link>	
		<description>Is there a way in Windows XP Pro where I can set up a folder to automatically export the data that Ive put into it, when it reaches a certain size? &lt;br /&gt;&lt;br /&gt; Ive subscribed to a number of Podcasts, as this is the new hip thing to do, however I&apos;ve not got an Ipod or MP3 player, but I have got an mp3 CD player. &lt;br&gt;
So I was wondering if I was able to set a folder up that would fill up to about the size of a CD, and then export this data into another folder, which I could then burn and listen to?&lt;br&gt;
I know this is easily done manually but was just hoping there was a cheeky shortcut that I could use instead.</description>
		<guid isPermaLink="false">post:ask.metafilter.com,2005:site.27572</guid>
		<pubDate>Sun, 20 Nov 2005 09:06:31 -0800</pubDate>
		<dc:creator>djstig</dc:creator>
		
			<category>data</category>
		
			<category>folders</category>
		
			<category>xp</category>
		
			<category>windows</category>
		
			<category>podcast</category>
		
	</item> <item>
		<title>By: purephase</title>
		<link>http://ask.metafilter.com/27572/How-to-export-data-in-folders#434504</link>	
		<description>I&apos;ve never used &lt;a href=&quot;http://www.karenware.com/powertools/ptreplicator.asp&quot;&gt;this&lt;/a&gt; application, but it might do what you&apos;re looking for.&lt;br&gt;
&lt;br&gt;
You could also write a small script that you could attach to a scheduled task that could check the folder size each hour (or for whenever you specify) and then copy the folder contents over to your burn folder. I&apos;m not sure of what your proficiency is with Windows so I haven&apos;t provided the script code here. Let me know if you want it.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2005:site.27572-434504</guid>
		<pubDate>Sun, 20 Nov 2005 09:29:44 -0800</pubDate>
		<dc:creator>purephase</dc:creator>
	</item><item>
		<title>By: djstig</title>
		<link>http://ask.metafilter.com/27572/How-to-export-data-in-folders#435144</link>	
		<description>Oh cheers I&apos;ve downloaded that program, but I was thinking more of a script thingy.&lt;br&gt;
&lt;br&gt;
Any one else got any ideas?&lt;br&gt;
&lt;br&gt;
Cheers</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2005:site.27572-435144</guid>
		<pubDate>Mon, 21 Nov 2005 03:34:34 -0800</pubDate>
		<dc:creator>djstig</dc:creator>
	</item><item>
		<title>By: purephase</title>
		<link>http://ask.metafilter.com/27572/How-to-export-data-in-folders#435184</link>	
		<description>Copy/paste the following into a file called &quot;ManageFolder.wsf&quot; (using notepad -- without quotes):&lt;br&gt;
&lt;code&gt;&lt;br&gt;
&amp;lt;package&amp;gt;&lt;br&gt;
&amp;lt;job id=&quot;manage_folder&quot;&amp;gt;&lt;br&gt;
&amp;lt;script language=&quot;vbscript&quot;&amp;gt;&lt;br&gt;
&lt;br&gt;
    Option Explicit&lt;br&gt;
    On Error Resume Next&lt;br&gt;
&lt;br&gt;
    Dim strFolderToMonitor, strFolderToCopyTo, intFileSizeLimit&lt;br&gt;
&lt;br&gt;
    &apos; Only change these variables.&lt;br&gt;
    strFolderToMonitor  = &quot;&amp;lt;PATH&amp;gt;&quot;  &apos; Full path to the folder to monitor. (eg. c:\original) -- DO NOT USE A TRAILING SLASH!&lt;br&gt;
    strFolderToCopyTo   = &quot;&amp;lt;PATH&amp;gt;&quot;  &apos; Full path to the destination folder. The files from the above folder will be copied here. Same format as above.&lt;br&gt;
    intFileSizeLimit    = 700             &apos; The maximum file size in MB. Once the contents of the original folder reach this size, they will be copied over.&lt;br&gt;
&lt;br&gt;
    &apos; Declare objects.&lt;br&gt;
    Dim FSO: Set FSO = CreateObject(&quot;Scripting.FileSystemObject&quot;)&lt;br&gt;
&lt;br&gt;
    &apos; Check to see if the source and destination folders exist.&lt;br&gt;
    If FSO.FolderExists(strFolderToMonitor) And FSO.FolderExists(strFolderToCopyTo) Then&lt;br&gt;
        Dim FolderToMonitor&lt;br&gt;
&lt;br&gt;
        Set FolderToMonitor = FSO.GetFolder(strFolderToMonitor)&lt;br&gt;
&lt;br&gt;
        &apos; Check the folder size. It&apos;s returned in bytes so convert it to match MB value above.&lt;br&gt;
        If FolderToMonitor.Size &amp;gt;= (intFileSizeLimit * 1024) * 1024 Then&lt;br&gt;
            Dim File&lt;br&gt;
&lt;br&gt;
            &apos; The folder size was greater than fileSizeLimit specified, copy each of the files from the original folder over to the destination.&lt;br&gt;
            For Each File in FolderToMonitor.Files&lt;br&gt;
                File.Copy(strFolderToCopyTo &amp;amp; &quot;\&quot;)&lt;br&gt;
&lt;br&gt;
                If Not Err Then&lt;br&gt;
                    &apos; The file was successfully copied, delete it from the original folder.&lt;br&gt;
                    File.Delete&lt;br&gt;
                End If&lt;br&gt;
            Next&lt;br&gt;
        End If&lt;br&gt;
&lt;br&gt;
        Set FolderToMonitor = Nothing&lt;br&gt;
    End If&lt;br&gt;
&lt;br&gt;
    Set FSO = Nothing&lt;br&gt;
    WScript.Quit&lt;br&gt;
&amp;lt;/script&amp;gt;&lt;br&gt;
&amp;lt;/job&amp;gt;&lt;br&gt;
&amp;lt;/package&amp;gt;&lt;br&gt;
&lt;/code&gt;&lt;br&gt;
Once you have it in notepad, change the strFolderToMonitor variable to match the folder you want to copy the files from, where the strFolderToCopyTo is your destination (burn folder).&lt;br&gt;
&lt;br&gt;
Once the ManageFolder.wsf file is saved copy/paste the following into a .bat file (using notepad):&lt;br&gt;
&lt;code&gt;&lt;br&gt;
cscript ManageFolder.wsf&lt;br&gt;
&lt;/code&gt;&lt;br&gt;
Make sure that both files are in the same folder (I would recommend a separate folder from either the monitored folder or the destination folder).&lt;br&gt;
&lt;br&gt;
Setup a scheduled task (Start-&amp;gt;Settings-&amp;gt;Control Panel-&amp;gt;Scheduled Tasks) that runs the batch file (the second file you created) at a specified time interval (hourly, daily etc). You shouldn&apos;t have to dig too deeply into any of the advanced settings for the scheduled task for this to work properly.&lt;br&gt;
&lt;br&gt;
If you have any problems, let me know.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2005:site.27572-435184</guid>
		<pubDate>Mon, 21 Nov 2005 05:32:32 -0800</pubDate>
		<dc:creator>purephase</dc:creator>
	</item><item>
		<title>By: djstig</title>
		<link>http://ask.metafilter.com/27572/How-to-export-data-in-folders#435255</link>	
		<description>Ohh ta very much, I&apos;ll have a fiddle with that.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2005:site.27572-435255</guid>
		<pubDate>Mon, 21 Nov 2005 07:16:46 -0800</pubDate>
		<dc:creator>djstig</dc:creator>
	</item>
	</channel>
</rss>
