[THIN] Re: OT: VBScript assistance needed

  • From: "Andrew Wood" <andrew.wood@xxxxxxxxxxxxxxxx>
  • To: <thin@xxxxxxxxxxxxx>
  • Date: Tue, 28 Apr 2009 09:33:39 +0100

Is this a pure TS environment? If you've Ctx you could use MFCOM you could
do :-

 

For each asession in oMFServer.Sessions

                Assession.logoff(false)

Next 

 

Where oMFServer is an metaframecom.metaframeserver object for the current
machine

 

Failing that you could always enumerate the sessions and run a logoff
command for each one. 

 

From: thin-bounce@xxxxxxxxxxxxx [mailto:thin-bounce@xxxxxxxxxxxxx] On Behalf
Of Steve Snyder
Sent: 28 April 2009 02:13
To: thin@xxxxxxxxxxxxx
Subject: [THIN] OT: VBScript assistance needed

 

trying to implement a logoff in vbscript, a la

set objOS -
getobject("winmgmts:{(Shutdown)}//.root/cimv2").execquery("select * from
win32_operatingsystem where primary=true")
for each objsys in objOS
  objsys.win32shutdown 0
next

 which works great on a 32bit windows system, not so great on a 64bit
windows system. Any ideas how to make this fly on 64bit?

Other related posts: