How can I make a ps-script that checks if a scheduled task was running in the last 24 hours and if not gives me an error echo? How do I check if a page is active and no 404 error is shown in selenium?