Well, I can give you thousands of another unreasonable fixes or you can send us the text of the exception :).
2009/12/17 Marcus <[email protected]> > But the TimeSpan constructor wants integers, so 0.2 is not a valid > value... > > On 17 Dec, 12:43, Processor Devil <[email protected]> wrote: > > sry, wrongly typed, I wanted to say to try 0.2 seconds, not 2 seconds :D > > > > 2009/12/17 Processor Devil <[email protected]> > > > > > > > > > It shouldn't make difference, but try to use 2 seconds instead of 200 > > > miliseconds, if it works then there is some problem with TimeSpan > conversion > > > and not the WQL Query... > > > > > 2009/12/17 Marcus <[email protected]> > > > > > Can someone explain to me why this code works (C#): > > > > >> WqlEventQuery procCreateQuery = new WqlEventQuery( > > >> "__InstanceCreationEvent", > > >> new TimeSpan(0, 0, 1), > > >> "TargetInstance isa \"Win32_Process\"); > > > > >> and also this works... > > > > >> WqlEventQuery procCreateQuery = new WqlEventQuery( > > >> "__InstanceCreationEvent", > > >> new TimeSpan(200), > > >> "TargetInstance isa \"Win32_Process\"); > > > > >> ...while the following gets "unparsable query": > > > > >> WqlEventQuery procCreateQuery = new WqlEventQuery( > > >> "__InstanceCreationEvent", > > >> new TimeSpan(0, 0, 0, 0, 200), > > >> "TargetInstance isa \"Win32_Process\"); > > > > >> Another strange thing is that I think I used to run the one that now > > >> fails, successfully aswell, but all of a sudden I can't. > > >> So I am allowed to poll at 1 second intervall aswell as 20 > > >> microseconds intervall but NOT at 200 milliseconds intervall? > > > > >> Does someone know what is going on here?- Dölj citerad text - > > > > - Visa citerad text - >
