home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 1
MediaPortal 1 Talk
VBScript Clean MediaPortal Exit needed
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="yogi_bear_79" data-source="post: 362586" data-attributes="member: 87299"><p>I frequently admin my HTPC via RDC. I'm looking for a clean VBScript way of shutting down MediaPortal if it is running when I connect via RDC.</p><p></p><p>Basic concept would be, call the VBScript from the RDC client under the Programs tab, "Start the following program on connection"</p><p></p><p>My reasoning is, since RDC is only capable of supporting 16-Bit Colors MediaPortal doesn't react well when I RDC in.</p><p></p><p>I tried this, which works, but causes MediaPortal to start the crashed unexpectedly window:</p><p></p><p>strComputer = "."</p><p>Set objWMIService = GetObject("winmgmts:" _</p><p> & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")</p><p></p><p>Set colProcessList = objWMIService.ExecQuery _</p><p> ("Select * from Win32_Process Where Name = 'MediaPortal.exe'")</p><p></p><p>For Each objProcess in colProcessList</p><p> objProcess.Terminate()</p><p>Next</p><p></p><p>Well, I got my Dameware working and it supports 32Bit, so Soultion in't really needed, unless others need it.</p></blockquote><p></p>
[QUOTE="yogi_bear_79, post: 362586, member: 87299"] I frequently admin my HTPC via RDC. I'm looking for a clean VBScript way of shutting down MediaPortal if it is running when I connect via RDC. Basic concept would be, call the VBScript from the RDC client under the Programs tab, "Start the following program on connection" My reasoning is, since RDC is only capable of supporting 16-Bit Colors MediaPortal doesn't react well when I RDC in. I tried this, which works, but causes MediaPortal to start the crashed unexpectedly window: strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") Set colProcessList = objWMIService.ExecQuery _ ("Select * from Win32_Process Where Name = 'MediaPortal.exe'") For Each objProcess in colProcessList objProcess.Terminate() Next Well, I got my Dameware working and it supports 32Bit, so Soultion in't really needed, unless others need it. [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 1
MediaPortal 1 Talk
VBScript Clean MediaPortal Exit needed
Contact us
RSS
Top
Bottom