Guest qq Posted March 11, 2008 Posted March 11, 2008 Hi All, I want to run a login script file for certain users. How can I know these users has login to domain? How can I track these users' login status? Thanks in advance,
Guest Pegasus \(MVP\) Posted March 11, 2008 Posted March 11, 2008 Re: User login "qq" <qq@discussions.microsoft.com> wrote in message news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... > Hi All, > > I want to run a login script file for certain users. How can I know these > users has login to domain? How can I track these users' login status? > > Thanks in advance, You could get these users to execute a modified logon script that contains this line of code: echo %date% %time:~0,5% %UserName% >> \\YourServer\SomeShare\Logs\logon.txt
Guest JohnB Posted March 12, 2008 Posted March 12, 2008 Re: User login Ok, it's the BrainSponge again.... In the line where you're sending the screen output to a file, what does this part mean: ":~0,5% " "Pegasus (MVP)" <I.can@fly.com.oz> wrote in message news:uY60VJ8gIHA.536@TK2MSFTNGP06.phx.gbl... > > "qq" <qq@discussions.microsoft.com> wrote in message > news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... >> Hi All, >> >> I want to run a login script file for certain users. How can I know these >> users has login to domain? How can I track these users' login status? >> >> Thanks in advance, > > You could get these users to execute a modified logon script > that contains this line of code: > > echo %date% %time:~0,5% %UserName% >> > \\YourServer\SomeShare\Logs\logon.txt >
Guest Pegasus \(MVP\) Posted March 12, 2008 Posted March 12, 2008 Re: User login IMHO, far too few people probe a little deeper when looking for batch file answers here. Most are happy to use the code without really understanding what it does. When you type set /? then you will see that the command has the ability to perform substring functions. The %time% variable looks like so: 16:17:38.67, which is fairly useless for the OP's purpose, so how about using only the 5 left-most characters? This command will do it: echo %time:~0,5% "JohnB" <jbrigan@yahoo.com> wrote in message news:uhtaK3EhIHA.1188@TK2MSFTNGP04.phx.gbl... > Ok, it's the BrainSponge again.... > > In the line where you're sending the screen output to a file, what does > this > part mean: ":~0,5% " > > > > "Pegasus (MVP)" <I.can@fly.com.oz> wrote in message > news:uY60VJ8gIHA.536@TK2MSFTNGP06.phx.gbl... >> >> "qq" <qq@discussions.microsoft.com> wrote in message >> news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... >>> Hi All, >>> >>> I want to run a login script file for certain users. How can I know >>> these >>> users has login to domain? How can I track these users' login status? >>> >>> Thanks in advance, >> >> You could get these users to execute a modified logon script >> that contains this line of code: >> >> echo %date% %time:~0,5% %UserName% >> >> \\YourServer\SomeShare\Logs\logon.txt >> > >
Guest JohnB Posted March 12, 2008 Posted March 12, 2008 Re: User login mucho gracias "Pegasus (MVP)" <I.can@fly.com.oz> wrote in message news:O0LNESFhIHA.4164@TK2MSFTNGP05.phx.gbl... > IMHO, far too few people probe a little deeper when looking > for batch file answers here. Most are happy to use the code > without really understanding what it does. > > When you type set /? then you will see that the command > has the ability to perform substring functions. The %time% > variable looks like so: 16:17:38.67, which is fairly useless > for the OP's purpose, so how about using only the 5 left-most > characters? This command will do it: > echo %time:~0,5% > > > "JohnB" <jbrigan@yahoo.com> wrote in message > news:uhtaK3EhIHA.1188@TK2MSFTNGP04.phx.gbl... >> Ok, it's the BrainSponge again.... >> >> In the line where you're sending the screen output to a file, what does >> this >> part mean: ":~0,5% " >> >> >> >> "Pegasus (MVP)" <I.can@fly.com.oz> wrote in message >> news:uY60VJ8gIHA.536@TK2MSFTNGP06.phx.gbl... >>> >>> "qq" <qq@discussions.microsoft.com> wrote in message >>> news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... >>>> Hi All, >>>> >>>> I want to run a login script file for certain users. How can I know >>>> these >>>> users has login to domain? How can I track these users' login status? >>>> >>>> Thanks in advance, >>> >>> You could get these users to execute a modified logon script >>> that contains this line of code: >>> >>> echo %date% %time:~0,5% %UserName% >> >>> \\YourServer\SomeShare\Logs\logon.txt >>> >> >> > >
Guest Pegasus \(MVP\) Posted March 12, 2008 Posted March 12, 2008 Re: User login "JohnB" <jbrigan@yahoo.com> wrote in message news:%23PiUwrFhIHA.5164@TK2MSFTNGP03.phx.gbl... > mucho gracias My pleasure.
Guest qq Posted March 12, 2008 Posted March 12, 2008 Re: User login Thank you so much for you help. I am new for using Login script. Would you have any web site which is better for me to start write and setup login script on windows 2000 server? Thanks a lot. "Pegasus (MVP)" wrote: > > "qq" <qq@discussions.microsoft.com> wrote in message > news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... > > Hi All, > > > > I want to run a login script file for certain users. How can I know these > > users has login to domain? How can I track these users' login status? > > > > Thanks in advance, > > You could get these users to execute a modified logon script > that contains this line of code: > > echo %date% %time:~0,5% %UserName% >> \\YourServer\SomeShare\Logs\logon.txt > > >
Guest Pegasus \(MVP\) Posted March 12, 2008 Posted March 12, 2008 Re: User login Some login scripts are just a collection of Command Line commands. Here is a site that explains them: http://commandwindows.com/index.html "qq" <qq@discussions.microsoft.com> wrote in message news:FC7FC3AA-0AA4-41AD-8C28-D5A509D88ADF@microsoft.com... > Thank you so much for you help. > > I am new for using Login script. Would you have any web site which is > better > for me to start write and setup login script on windows 2000 server? > Thanks a > lot. > > "Pegasus (MVP)" wrote: > >> >> "qq" <qq@discussions.microsoft.com> wrote in message >> news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... >> > Hi All, >> > >> > I want to run a login script file for certain users. How can I know >> > these >> > users has login to domain? How can I track these users' login status? >> > >> > Thanks in advance, >> >> You could get these users to execute a modified logon script >> that contains this line of code: >> >> echo %date% %time:~0,5% %UserName% >> >> \\YourServer\SomeShare\Logs\logon.txt >> >> >>
Guest qq Posted March 13, 2008 Posted March 13, 2008 Re: User login Thank you so much for your help. "Pegasus (MVP)" wrote: > Some login scripts are just a collection of Command Line > commands. Here is a site that explains them: > http://commandwindows.com/index.html > > > "qq" <qq@discussions.microsoft.com> wrote in message > news:FC7FC3AA-0AA4-41AD-8C28-D5A509D88ADF@microsoft.com... > > Thank you so much for you help. > > > > I am new for using Login script. Would you have any web site which is > > better > > for me to start write and setup login script on windows 2000 server? > > Thanks a > > lot. > > > > "Pegasus (MVP)" wrote: > > > >> > >> "qq" <qq@discussions.microsoft.com> wrote in message > >> news:2F420F91-1C24-4D94-9AE2-2FF81D4C501A@microsoft.com... > >> > Hi All, > >> > > >> > I want to run a login script file for certain users. How can I know > >> > these > >> > users has login to domain? How can I track these users' login status? > >> > > >> > Thanks in advance, > >> > >> You could get these users to execute a modified logon script > >> that contains this line of code: > >> > >> echo %date% %time:~0,5% %UserName% >> > >> \\YourServer\SomeShare\Logs\logon.txt > >> > >> > >> > > >
Recommended Posts