WQL Problem

Discussion in 'Windows XP WMI' started by screamingveg, Feb 21, 2006.

  1. screamingveg

    screamingveg

    Joined:
    Feb 21, 2006
    Messages:
    1
    Likes Received:
    0
    I'm trying to write a script that will grab the event logs from a remote computer for a specific day. I've got everything set up just how I want it, except the following line doesn't work:

    Set colItems = objWMIService.ExecQuery("SELECT * FROM Win32_NTLogEvent WHERE TimeGenerated LIKE " & dayt & " %",,48)

    When I try to use colItems for anything I get an error: 0x80041017

    dayt is an 8 character string that looks like this: 20060131
    It gets set to today's date when the script is run.

    If anyone has any idea why this isn't working, or can offer me any help at all it would be most appreciated.
     
    screamingveg, Feb 21, 2006
    #1
    1. Advertisements

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Aaron

    WQL & Parameters

    Aaron, Jan 19, 2005, in forum: Windows XP WMI
    Replies:
    3
    Views:
    2,961
    Torgeir Bakken \(MVP\)
    Jan 20, 2005
  2. rs

    Help with WQL query

    rs, Mar 4, 2005, in forum: Windows XP WMI
    Replies:
    1
    Views:
    7,288
    Peter Falz
    Mar 4, 2005
  3. sedyn

    Deep WQL Query

    sedyn, Aug 26, 2005, in forum: Windows XP WMI
    Replies:
    0
    Views:
    962
    sedyn
    Aug 26, 2005
  4. Koti
    Replies:
    1
    Views:
    2,852
    andrew
    Sep 8, 2005
  5. Koti
    Replies:
    4
    Views:
    18,118
    sunitnair
    Sep 10, 2005
Loading...

Share This Page