Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
run macro after reboot
#1
can I run something after next reboot? If I use system restore some files are corrupted through this action. I want to replace these files with correctly ones after the new system restore point is build, that means after reboot with this point.
#2
yes, you can create your macro and then 'schedule' it via the macro's properties (ctl-p) then go to the Windows Schedule Task folder and open the new task then click on the Schedule tab then in the 'Schedule Task' choose at 'System Startup' and it'll start up when the machine reboots. if you only want it to run on the next startup, go into the Advanced tab and set it to start and end on the same day or have the macro put the command 'end' at the front of itself after running the commands you want.
An old blog on QM coding and automation.

The Macro Hook
#3
Here is how a macro can tell Windows to run another macro when Windows starts next time:
Macro
Code:
Copy      Help
;set registry value that tells Windows to run QM and macro "macro x" when Windows starts
rset "qmcl.exe M ''Macro x''" "QM - macro x" "Software\Microsoft\Windows\CurrentVersion\Run"

In macro x insert this at the beginning:
Macro
Code:
Copy      Help
if(!rget(_s "QM - macro x" "Software\Microsoft\Windows\CurrentVersion\Run")) ret ;;don't run accidentally if not set
rset "" "QM - macro x" "Software\Microsoft\Windows\CurrentVersion\Run" 0 -1 ;;delete the value


Forum Jump:


Users browsing this thread: 1 Guest(s)