WQL Problem

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

  1. screamingveg

    screamingveg

    Joined:
    Feb 21, 2006
    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:
    3,095
    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,677
    Peter Falz
    Mar 4, 2005
  3. sedyn

    Deep WQL Query

    sedyn, Aug 26, 2005, in forum: Windows XP WMI
    Replies:
    0
    Views:
    1,022
    sedyn
    Aug 26, 2005
  4. Koti
    Replies:
    1
    Views:
    2,997
    andrew
    Sep 8, 2005
  5. Koti
    Replies:
    4
    Views:
    18,813
    sunitnair
    Sep 10, 2005
  6. Guest
    Replies:
    0
    Views:
    941
    Guest
    Jun 29, 2006
  7. Phil Sharpe

    WQL question

    Phil Sharpe, Aug 7, 2007, in forum: Windows XP WMI
    Replies:
    0
    Views:
    452
    Phil Sharpe
    Aug 7, 2007
  8. Alejandro martinez

    WQL - kill process

    Alejandro martinez, Apr 22, 2009, in forum: Windows XP WMI
    Replies:
    2
    Views:
    1,337
    Alex K. Angelopoulos
    May 8, 2009
Loading...