Batch can't polling, but you can try this VBScript:
Option Explicit
Const Path = "%userprofile%\Documents\Folder"
Const Interval = 1
Const Delay = 60
Dim oWSH, oFSO, oWMI, oEvent, oTarget, colEvents
Dim sPath, sDrive, sFolder, sNewPath
Set oWSH = CreateObject("WScript.Shell")
Set oFSO = CreateObject("Scripting.FileSystemObject")
oWSH.CurrentDirectory = oFSO.GetParentFolderName(WScript.ScriptFullName)
sPath = oWSH.ExpandEnvironmentStrings(Path)
sPath = oFSO.GetAbsolutePathName(sPath)
If Not oFSO.FolderExists(sPath) Then oFSO.CreateFolder(sPath)
sDrive = oFSO.GetDriveName(sPath)
sFolder = Replace(Mid(sPath, 3) & "\", "\", "\\", 1, -1, vbTextCompare)
Set oWMI = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
Set colEvents = oWMI.ExecNotificationQuery( _
"SELECT * FROM __InstanceCreationEvent" _
& " WITHIN " & CStr(Interval) _
& " WHERE Targetinstance ISA 'CIM_DataFile'" _
& " AND TargetInstance.Drive='" & sDrive & "'"_
& " AND TargetInstance.Path='" & sFolder & "'")
Do
Set oEvent = colEvents.NextEvent()
sNewPath = Year(Now) & "_" & Right("0" & Month(Now), 2) & "_" & Right("0" & Day(Now), 2)
sNewPath = oFSO.BuildPath(sPath, sNewPath)
If Not oFSO.FolderExists(sNewPath) Then oFSO.CreateFolder(sNewPath)
Set oTarget = oEvent.TargetInstance
WScript.Sleep Delay * 1000
On Error Resume Next
oFSO.MoveFile oTarget.Name, oFSO.BuildPath(sNewPath, oFSO.GetFileName(oTarget.Name))
On Error Goto 0
Loop
What OS are you trying to do this on? – slm – 2013-04-07T10:56:28.103
I am working on windows – patro – 2013-04-07T13:36:11.737