I think he is taking the piss on me \:\)

The rundll doesn't work on a terminal server but i solved it with the following lines in a bat file:

query session >session.txt
for /f "skip=1 tokens=3," %%i in (session.txt) DO logoff %%i
del session.txt

However i am still strugling I cant get any oytput from:

? $time Join(Split(@TIME, ":"), "")

Regards Glenn