Go to Macro Toolworks, download the free version and create a Trigger for a time-based macro! It's quite easy! That apps could do much more, include a lot automated processes etc.!!
Here is what I did. I created a .cmd file (same as .bat, but I prefer,) and named it sfc.cmd Code: sfc /scannow I placed it on C-drive. Then I created a shortcut, and placed it on C-drive also. I click on properties, advanced, and set it to run as administrator. Then I went into task scheduler and created a task to run every night at 12:01 a.m. Here is the file. Save it as .xml in notepad, open Schedule Tasks, and import. You are good to go. Spoiler Code: <?xml version="1.0" encoding="UTF-16"?><Task version="1.4" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task"> <RegistrationInfo> <URI>\SFC</URI> </RegistrationInfo> <Triggers> <CalendarTrigger> <StartBoundary>2016-01-17T12:01:00</StartBoundary> <Enabled>true</Enabled> <ScheduleByDay> <DaysInterval>1</DaysInterval> </ScheduleByDay> </CalendarTrigger> </Triggers> <Principals> <Principal id="Author"> <GroupId>S-1-5-32-545</GroupId> <RunLevel>HighestAvailable</RunLevel> </Principal> </Principals> <Settings> <MultipleInstancesPolicy>IgnoreNew</MultipleInstancesPolicy> <DisallowStartIfOnBatteries>true</DisallowStartIfOnBatteries> <StopIfGoingOnBatteries>true</StopIfGoingOnBatteries> <AllowHardTerminate>true</AllowHardTerminate> <StartWhenAvailable>false</StartWhenAvailable> <RunOnlyIfNetworkAvailable>false</RunOnlyIfNetworkAvailable> <IdleSettings> <StopOnIdleEnd>true</StopOnIdleEnd> <RestartOnIdle>false</RestartOnIdle> </IdleSettings> <AllowStartOnDemand>true</AllowStartOnDemand> <Enabled>true</Enabled> <Hidden>false</Hidden> <RunOnlyIfIdle>false</RunOnlyIfIdle> <DisallowStartOnRemoteAppSession>false</DisallowStartOnRemoteAppSession> <UseUnifiedSchedulingEngine>true</UseUnifiedSchedulingEngine> <WakeToRun>false</WakeToRun> <ExecutionTimeLimit>PT72H</ExecutionTimeLimit> <Priority>7</Priority> </Settings> <Actions Context="Author"> <Exec> <Command>C:\sfc.cmd</Command> </Exec> </Actions> </Task>
technet.microsoft.com/en-us/library/cc748993.aspx windows.microsoft.com/en-US/windows/schedule-task#1TC=windows-7
use taskschd.msc define your action and triggers and you're done. takes about 5min. also can import/export it as xml (for other machines)
https://technet.microsoft.com/en-us/library/cc722129.aspx : The following list contains a description of each action and the action settings. • Start a program This action starts a program or script. In the Program/script text box, enter the name of the program or script you want to start. If the program or script takes command line arguments, you can supply these arguments in the Add arguments (optional) text box. In the Start in (optional) text box, you can specify the working directory for the command line that executes the program or script. This should be either the path to the program or script file or the path to the files that are used by the executable file.