Re: Logging off session after closing application
From: eddie (eddie_at_discussions.microsoft.com)
Date: 02/14/05
- Next message: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Previous message: Ray Joslyn: "Re: terminal services sessions question"
- In reply to: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Next in thread: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Reply: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 14 Feb 2005 12:45:04 -0800
The test works fine, but if I run the batch file from within the ts session
the same happens as before - when the application is starting it tries to
logoff the session before it comes up...
I think I'll try to find another solution, but if You will take a look at
the batch file a last time to see if there is something wrong with the syntax
it would be fine.
start /wait \\server\folder\foxproapp.exe
logoff
Thanks
"Vera Noest [MVP]" wrote:
> That's weird! start /wait is a standard command.
> Could you try it in a command window?
> Open a command windows (Run cmd) and type
> "start /wait echo Waiting" (without the quotes)
> You should see a second window which executes the "echo" command
> and displays the output: "Waiting", followed by your current
> directory and the cursor. This represents your 16-bit application.
> The first window is waiting for the second application to end and
> is therefore *not* returning to the cursor.
> Now quit the application (type "exit" in the second command window)
> and you will see that the first window continues execution and
> returns you to the command prompt.
>
> If this works (and it better should, or you have something really
> strange going on), can you try this: log on to the TS desktop
> without defining a starting application, and run the batfile
> interactively? Does it run the application then, or does it execute
> the logoff command without waiting for the application to finish?
>
> --
> Vera Noest
> MCSE, CCEA, Microsoft MVP - Terminal Server
> http://hem.fyristorg.com/vera/IT
> --- please respond in newsgroup, NOT by private email ---
>
> "=?Utf-8?B?ZWRkaWU=?=" <eddie@discussions.microsoft.com> wrote on
> 13 feb 2005 in microsoft.public.windows.terminal_services:
>
> > Thanks for the answer..
> >
> > I ment shutdown /l by the way.
> >
> > It is a 16-bit application.
> > I have created a batch file and used start /wait and the
> > application starts when I logon but tries to log me off
> > immediately . It seems that the wait command does not work
> >
> > eddie
> >
> >
> > "Vera Noest [MVP]" wrote:
> >
> >> "shutdown /r" as the last line???
> >> Do you want your users to reboot the server everytime they quit
> >> an application?
> >>
> >> If the application is a 32-bit application, you should not need
> >> to do anything, because quitting the application automatically
> >> ends the TS session.
> >> If it is a 16-bit application, you could have a problem with
> >> the ntvdm not closing, and thereby preventing the session from
> >> ending. If that's the case, try this:
> >>
> >> create a batfile, lets say "start_my_16_bit_app.bat", which
> >> contains:
> >>
> >> start /wait my_16_bit_app.exe
> >> logoff
> >>
> >> Define this batfile as the starting application in the users TS
> >> session.
> >>
> >> --
> >> Vera Noest
> >> MCSE, CCEA, Microsoft MVP - Terminal Server
> >> http://hem.fyristorg.com/vera/IT
> >> --- please respond in newsgroup, NOT by private email ---
> >>
> >> "=?Utf-8?B?ZWRkaWU=?=" <eddie@discussions.microsoft.com> wrote
> >> on 13 feb 2005 in microsoft.public.windows.terminal_services:
> >>
> >> > Case:
> >> > Windows 2003 terminalserver.
> >> > I have som users with this demand (they are in a separate
> >> > GPO)
> >> >
> >> > 1. When they start a ts session an application shall start
> >> > (This part is OK - I use GPO or Active Dir Users and Comp)
> >> >
> >> > 2. When they are finished with the application and quit the
> >> > application the normal way, I want the terminalsession to be
> >> > logged off automatically.
> >> >
> >> > i have tried to make a startup script with shutdown /r as the
> >> > last line but I 'm not sure how I can get the script to wait
> >> > until the application finish, and then execute logoff /r.
> >> >
> >> > Eddie
>
- Next message: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Previous message: Ray Joslyn: "Re: terminal services sessions question"
- In reply to: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Next in thread: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Reply: Vera Noest [MVP]: "Re: Logging off session after closing application"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|