Task scheduler ONEVENT Schedule Frequency.

Discussion in 'Windows Vista General Discussion' started by Wake-Up-Jeff, Jul 4, 2007.

  1. Wake-Up-Jeff

    Wake-Up-Jeff Guest

    The vista task scheduler schtasks.exe provides the facility to take an
    action when an event has been recorded in the Windows event log.

    This facility is only really useful if the triggered action has access to
    aspects of the event, such as date, time and event message. Is there any way
    to get this information passed to the triggered action from the event log

    I can't see a way, either by using the command line schtasks.exe, or the
    task scheduler GUI.
    Wake-Up-Jeff, Jul 4, 2007
    1. Advertisements

  2. Wake-Up-Jeff

    Jon Guest

    Don't know of way of doing that, but since you know the event id / log that
    triggered it, the task that runs can process the Event Logs for the most
    recent event with that particular event id.
    Jon, Jul 4, 2007
    1. Advertisements

  3. Wake-Up-Jeff

    Wake-Up-Jeff Guest

    Agreed. But I think that is a little clumsy.
    In this case, it would be better to use WMI, which at least gives you the
    event detail when the event is triggered.
    I would prefer to use the scheduler, as it gives a nice interface, and it
    provides a really rich environment for event triggers.
    Wake-Up-Jeff, Jul 4, 2007
  4. Wake-Up-Jeff

    Jon Guest

    Not ideal, I agree. It's a pity there's not more information being passed as
    argument to the task triggered by the event, although it's quite possible
    that there's hidden option that's not been documented, similar to the
    $(Arg0) that you can pass to a program etc. Would be interested too in
    knowing it, if there is. Would be nice if someone from MS could shed some
    light on the issue.
    Jon, Jul 4, 2007
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.