[REQ] Detection of RDP connection and closing MP

Discussion in 'Improvement Suggestions' started by Bram, October 12, 2006.

  1. Bram

    Bram Portal Pro

    Joined:
    December 12, 2005
    Messages:
    851
    Likes Received:
    3
    Occupation:
    Webapplication Developer (PHP, AJAX, MySQL, Backba
    Location:
    's-Hertogenbosch
    Ratings:
    +3 / 0
    Home Country:
    Netherlands Netherlands
    I use RDP (the Remote Desktop Protocol) to connect to my HTPC. I know about VNC (and software that does the same) but I don't want to use it. RDP is fast, efficient and in Windows out of the box. There is one disatvantage... DirectX doesn't workt thrue the RDP. So it's not possible to see MP thrue a RDP connection.

    What I do now is..

    - Connect with Remote Desktop
    - Once connected push CTRL+SHIFT+ESC as fast as I can and start clicking "End Task" hoping the taskmanager registers my input. This always works but might take some time.
    - Once MediaPortal is closed I see the desktop, but I have the taskbar hidden from within Media Portal (and I like to keep it that way), so I can't use the startmenu and quicklaunche shortcuts. To fix this I go to the TaskManager again and stop the "explorer.exe" task and restart it again by running "explorer" from the Run dialog.


    Now I can use the computer again. I could use a simple batch script to restart the explorer.exe task. But that still means I have to close MP manualy, which is a pain in the a** :)




    Is there a way to make MediaPortal detect if there is a RDP connection being made and optionaly close itself? I think some people use multiple concurent RDP sessions to manage their computer and don't want MP to close on a RDP connection. So it's probebly wise to make it optional, if at all possible.
     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. thachaser

    thachaser Portal Member

    Joined:
    January 11, 2006
    Messages:
    9
    Likes Received:
    0
    Occupation:
    Systems Administrator
    Location:
    Zwolle, NL
    Ratings:
    +0 / 0
    Hi,

    Maybe this helps :

    there's a program on the web, which allows you to connect with multiple RDP sessions to Windows XP.

    I don't know if i can post it here
     
  4. infinite.loop
    • Premium Supporter

    infinite.loop Retired Team Member

    Joined:
    December 26, 2004
    Messages:
    16,163
    Likes Received:
    3,861
    Gender:
    Male
    Location:
    127.0.0.1
    Ratings:
    +4,154 / 7
    Home Country:
    Austria Austria
    Show System Specs
    sure, you can post name and link to the homepage of this tool.
    as long as the application is not some kind of warez ;)
     
  5. Bram

    Bram Portal Pro

    Joined:
    December 12, 2005
    Messages:
    851
    Likes Received:
    3
    Occupation:
    Webapplication Developer (PHP, AJAX, MySQL, Backba
    Location:
    's-Hertogenbosch
    Ratings:
    +3 / 0
    Home Country:
    Netherlands Netherlands
    I know, but that is not what I prefer. I mainly use RDP to update MP with the latest SV, install codecs, maintain windows and work on a plugin for MP. I prefer to do all this on the same account on which MP is running with MP closed.
     
  6. thachaser

    thachaser Portal Member

    Joined:
    January 11, 2006
    Messages:
    9
    Likes Received:
    0
    Occupation:
    Systems Administrator
    Location:
    Zwolle, NL
    Ratings:
    +0 / 0
    http://riccardo.raneri.it/blog/eng/index.php/2006/04/24/windows-xp-multiuser-remote-desktop/

    You can find a manual example here.

    I'll post a link to the program tonight, because i don't have this @work

    Bram

    You can try to write a wsh script in vbs, that's detecting if you're running a RDP session. This has te be adjusted to run continueasly so it keeps checking for remote desktop.

    I found this here : http://www.fpschultze.de/smartfaq faq.faqid 87.htm :

    If fctCheckTS Then
    WScript.Echo "I am running on TS"
    End If
    Function fctCheckTS
    Dim objWsh : Set objWsh = WScript.Shell
    Select Case Left(objWsh.ExpandEnvironmentStrings("%SESSIONNAME%"),3) Case "RDP", "ICA"
    fctCheckTS = True
    Case Else
    fctCheckTS = False
    End Select
    End Function
     
  7. thachaser

    thachaser Portal Member

    Joined:
    January 11, 2006
    Messages:
    9
    Likes Received:
    0
    Occupation:
    Systems Administrator
    Location:
    Zwolle, NL
    Ratings:
    +0 / 0
  8. NickName
    • Premium Supporter

    NickName MP Donator

    Joined:
    June 23, 2006
    Messages:
    359
    Likes Received:
    12
    Occupation:
    Test Manager, Release Manager, Systems Administrat
    Location:
    Gold Coast
    Ratings:
    +12 / 0
    Home Country:
    You don't need am external program.
    You need the termserv.dll dated 8-5-2004 from XP Mediacentre beta version.
    You change one registry key, enable a rule in gpedit.msc, setup a second user and you're set. :)

    You can login remotely, leaving Mediaportal running (happy wife & kids) and login to a second (different) desktop on the same PC. Naturally you can login as the same account as Mediaportal runs on and Mediaportal is minimised automagically, not logged out. So simply put, two identical or different users, one remotely and one locally, both concurrently.

    This only works on XP Pro & XP Mediacentre, not XP Home.
    I've seen several PCs configured this way. ;-)

    Note to self: I must burnt a certain DLL & instructions to CD for safekeeping...

    Feel free to PM me.

    NickName.

    P.S. Forget what I said above, that link in the previous post (http://sala.pri.ee/?page_id=11) achieves the same thing easier...
     
  9. Marcusb
    • Premium Supporter

    Marcusb Retired Team Member

    Joined:
    February 16, 2005
    Messages:
    1,995
    Likes Received:
    29
    Location:
    Melbourne
    Ratings:
    +29 / 0
    As a small bit of additional help. I used to have the same issue with needing to restart Explorer for the start bar to come back, but now I just turn off that option in MP and then set the task bar to auto hide. This works much better and if MP is set to Always on Top then it never appears any way...
     
  10. Khris

    Khris Portal Pro

    Joined:
    July 2, 2005
    Messages:
    449
    Likes Received:
    0
    Occupation:
    IT Geek
    Location:
    Edmonton, AB
    Ratings:
    +0 / 0
    Home Country:
    Canada Canada
    Let me get this straight, you're reluctant to use a piece of software that is commonly used (and widely accepted) by others, and want a custom solution programmed into MP to suit your specific needs which may or may not be used by anyone else?

    Now I'm not trying to be an ass, however it just doesn't seem logical for the amount of trouble you're willing to go to, when the solution is already evident and simple.

    Log into the remote machine with VNC to shut down MP, then use Remote Desktop.
     
  11. thachaser

    thachaser Portal Member

    Joined:
    January 11, 2006
    Messages:
    9
    Likes Received:
    0
    Occupation:
    Systems Administrator
    Location:
    Zwolle, NL
    Ratings:
    +0 / 0
    VNC does in this way the same as RDP so that's no solution. (when using RDP all openened programs show up, except MP because of directX)

    The problem is that he wants to shutdown MP automatically when an RDP session is set-up.
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!