If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Rate Thread | Display Modes |
#1
|
|||
|
|||
how to get the title into task manger 'window'?
I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. tschus pyotr -- APL is a mistake, carried through to perfection. It is the language of the future for the programming techniques of the past: it creates a new generation of coding bums. -- Edsger W. Dijkstra, SIGPLAN Notices, Volume 17, Number 5 |
Ads |
#2
|
|||
|
|||
how to get the title into task manger 'window'?
On 19.09.2018 17:21, pyotr filipivich wrote:
I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Use the title command within your batch to set the title to any string you like. |
#3
|
|||
|
|||
how to get the title into task manger 'window'?
On Wed, 19 Sep 2018 16:36:54 GMT, Herbert Kleebauer
wrote: On 19.09.2018 17:21, pyotr filipivich wrote: I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Use the title command within your batch to set the title to any string you like. title "Yaar!" (It be talk like a pirate day. HTH) -- Bah, and indeed, Humbug. |
#4
|
|||
|
|||
how to get the title into task manger 'window'?
pyotr filipivich wrote:
I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Give the batch file a title when you run it, like: start "title" parms your.bat To see the syntax for the 'start' function, run 'start /?' at the command line. 'start' is an internal function within the command interpreter (cmd.exe). Sometimes you get "unknown command" if you just start the command line with 'start' (because whatever is the handler doesn't know you are entering a function from within cmd.exe). In that case, use: cmd /c start "title" parms your.bat ^__ or /k depending on how you want the shell to handle stdout Remember to enclose the batch file within double quotes if its path or file name have space characters. The window title will have a title of "batfilename - title". You see "Administrator - batfilename" if you are running the batch file inside the same command shell (which, in your case, was opened with admin privs) instead of loading another shell. If you want the new window opened by 'start' to close when the batch file ends, add 'exit' at the end of your batch file. -- Not a valid signature delimiter line. You used "dash dash space space" but a correct sigline is "dash dash space". Just one trailing space. |
#5
|
|||
|
|||
how to get the title into task manger 'window'?
On 9/19/2018 11:21 AM, pyotr filipivich wrote:
I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. tschus pyotr -- APL is a mistake, carried through to perfection. It is the language of the future for the programming techniques of the past: it creates a new generation of coding bums. -- Edsger W. Dijkstra, SIGPLAN Notices, Volume 17, Number 5 I use Nircmd to rename, change size, and change position of CMD windows: :: Change CMD Window title, size, and position :: ================================================== ============ SETLOCAL ENABLEEXTENSIONS & (TITLE _Overnight_NAS.bat) & ENDLOCAL START "" /WAIT "C:\Program Files\nircmd-x64\nircmd.exe" win setsize stitle "Administrator" -1300 0 1300 1090 -- Zaidy036 |
#6
|
|||
|
|||
how to get the title into task manger 'window'?
Zaidy036 wrote:
I use Nircmd to rename, change size, and change position of CMD windows: START "" /WAIT ... ^___ Could've set the new window's title right there. Because you did not use the /b switch (to reuse the current shell), the program loads in a new shell (which opens a new console window). You can use the title parameter of the 'start' command to specify the title for that new window. The /wait switch means leaving open the console window for the current shell until the called program/script exits in the other window. You'll end up with two windows open: for the console shell where you ran 'start' and the one for within which the program/script runs. |
#7
|
|||
|
|||
how to get the title into task manger 'window'?
VanguardLH on Wed, 19 Sep 2018 13:40:47 -0500 typed in
alt.windows7.general the following: pyotr filipivich wrote: I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Give the batch file a title when you run it, like: start "title" parms your.bat To see the syntax for the 'start' function, run 'start /?' at the command line. 'start' is an internal function within the command interpreter (cmd.exe). Sometimes you get "unknown command" if you just start the command line with 'start' (because whatever is the handler doesn't know you are entering a function from within cmd.exe). In that case, use: cmd /c start "title" parms your.bat ^__ or /k depending on how you want the shell to handle stdout Oh boy. Remember to enclose the batch file within double quotes if its path or file name have space characters. So, I run CommandPrompt.bat which just has cmd in it. At the command line I then type start "The batchfile title" zargent.bat The window title will have a title of "batfilename - title". You see "Administrator - batfilename" if you are running the batch file inside the same command shell (which, in your case, was opened with admin privs) instead of loading another shell. If you want the new window opened by 'start' to close when the batch file ends, add 'exit' at the end of your batch file. I'm seeing "Administrator: Bat-file Title" as it is. Something to try. -- pyotr filipivich Next month's Panel: Graft - Boon or blessing? |
#8
|
|||
|
|||
how to get the title into task manger 'window'?
Herbert Kleebauer on Wed, 19 Sep 2018 18:36:54 +0200
typed in alt.windows7.general the following: On 19.09.2018 17:21, pyotr filipivich wrote: I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Use the title command within your batch to set the title to any string you like. I do. setting Title ZZ Home Agent Bat results in the window title Administrator: ZZ Home Agent Bat how do I get "Administrator" to a) go away, b) be short enough I can see which "window title" on the task bar is which actual window? -- pyotr filipivich Next month's Panel: Graft - Boon or blessing? |
#9
|
|||
|
|||
how to get the title into task manger 'window'?
Herbert Kleebauer wrote:
pyotr filipivich wrote: I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Use the title command within your batch to set the title to any string you like. Learned something new. Thanks. https://en.wikipedia.org/wiki/Title_(command) Note that this (or using "start "title" parms") will not get rid of the "Administrator: " prefix in the shell's console window. That is shown because the OP is loading the command shell (cmd.exe) with elevated [admin] privs by running the .bat file within an already opened command shell with elevated privs, using a shortcut configured to run elevated, or using runas (or some other means I'm not remembering right now). Without elevated privileges, the console window would just be the name of the batch file or the title specified in a 'start' or 'title' command. That's a feature of the command interpreter (cmd.exe). To modify that shell program, you could try the suggestion at: https://serverfault.com/questions/35...le/35587#35587 From what I saw using HxD (hex editor), cmd.exe.mui uses two bytes per character for Unicode encoding, so "Administrator: 0%" will look like: A.d.m.i.n.i.s.t.r.a.t.o.r.:. .%.0 (where each dot is 00) or, in hex: 41 00 64 00 6D 00 69 00 6E 00 69 00 73 00 74 00 72 00 61 00 74 00 6F 00 72 00 3A 00 20 00 25 00 30 00 I'm not sure you want to delete the 2-byte chars for "Administrator: " which results in a shorter string. That might fire some alert about a modified system file. Instead I'd first try nullifying that substring, so it looks like: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 25 00 30 00 If that didn't work, then move the "%0" to the front of the string and nullifying out the rest of the string, as in: 25 00 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 The author says there should be 2 space chars before the "0%", so maybe you have to use: 00 00 25 00 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 Or use a different shell program with different behavior. Or load the command shell (cmd.exe) as a normal user (not elevated) if it doesn't run any program that needs admin privs. As an option mentioned in the above forum thread, if the batch file needs admin privs but can run under a different account (i.e., it does not need to only run under your Windows account), you could create a new account called, say, "A", that was in the Administrators security group (i.e., an admin account) and use "runas /user:a parms" which would have "A: batfile" as the shell's window title. Or copy cmd.exe from a Windows XP host to your Windows 7 host to some holding folder (do not copy atop the cmd.exe for Windows 7) and call that cmd.exe to load the batch file. I've read where that old shell program did not add "Adminstrator: " as prefix to the console window when that shell was loaded with admin privs. The "Administrator: " prefix in the title is a feature in cmd.exe to alert the user that they are running the command shell with elevated privileges. |
#10
|
|||
|
|||
how to get the title into task manger 'window'?
See my reply to Kleebauer. "Administrator: " is added as a flag in the
window title to alert the user that the shell has admin privileges. |
#11
|
|||
|
|||
how to get the title into task manger 'window'?
VanguardLH on Wed, 19 Sep 2018 17:34:01 -0500 typed in
alt.windows7.general the following: Herbert Kleebauer wrote: pyotr filipivich wrote: I run batch files. (well 'duh') Sometimes I'll have two or more running, but when I look at the task bar, all I see of the "title" is "Adminis..." IF I hover over the mouse, up pops the popup with the full title: e.G., "Administrator: ZZ Home Agent Bat". Is there a way to eliminate, remove, not display the "administrator" part, or is that a Feature? It occurs to me,that if I could rename "administrator" to something shorter (E.G., Adm, Me, ...) that would serve as a "solution" of sorts. Use the title command within your batch to set the title to any string you like. Learned something new. Thanks. https://en.wikipedia.org/wiki/Title_(command) Note that this (or using "start "title" parms") will not get rid of the "Administrator: " prefix in the shell's console window. That is shown because the OP is loading the command shell (cmd.exe) with elevated [admin] privs by running the .bat file within an already opened command shell with elevated privs, using a shortcut configured to run elevated, or using runas (or some other means I'm not remembering right now). Without elevated privileges, the console window would just be the name of the batch file or the title specified in a 'start' or 'title' command. That's a feature of the command interpreter (cmd.exe). To modify that shell program, you could try the suggestion at: https://serverfault.com/questions/35...le/35587#35587 From what I saw using HxD (hex editor), cmd.exe.mui uses two bytes per character for Unicode encoding, so "Administrator: 0%" will look like: A.d.m.i.n.i.s.t.r.a.t.o.r.:. .%.0 (where each dot is 00) or, in hex: 41 00 64 00 6D 00 69 00 6E 00 69 00 73 00 74 00 72 00 61 00 74 00 6F 00 72 00 3A 00 20 00 25 00 30 00 I'm not sure you want to delete the 2-byte chars for "Administrator: " which results in a shorter string. That might fire some alert about a modified system file. Instead I'd first try nullifying that substring, so it looks like: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 25 00 30 00 If that didn't work, then move the "%0" to the front of the string and nullifying out the rest of the string, as in: 25 00 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 The author says there should be 2 space chars before the "0%", so maybe you have to use: 00 00 25 00 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 Or use a different shell program with different behavior. Or load the command shell (cmd.exe) as a normal user (not elevated) if it doesn't run any program that needs admin privs. As an option mentioned in the above forum thread, if the batch file needs admin privs but can run under a different account (i.e., it does not need to only run under your Windows account), you could create a new account called, say, "A", that was in the Administrators security group (i.e., an admin account) and use "runas /user:a parms" which would have "A: batfile" as the shell's window title. Or copy cmd.exe from a Windows XP host to your Windows 7 host to some holding folder (do not copy atop the cmd.exe for Windows 7) and call that cmd.exe to load the batch file. I've read where that old shell program did not add "Adminstrator: " as prefix to the console window when that shell was loaded with admin privs. The "Administrator: " prefix in the title is a feature in cmd.exe to alert the user that they are running the command shell with elevated privileges. Be still my beating heart. No! Wait! not that still! (Ka-thump) -- pyotr filipivich Next month's Panel: Graft - Boon or blessing? |
#12
|
|||
|
|||
how to get the title into task manger 'window'?
VanguardLH on Wed, 19 Sep 2018 17:36:02 -0500 typed in
alt.windows7.general the following: See my reply to Kleebauer. "Administrator: " is added as a flag in the window title to alert the user that the shell has admin privileges. I did. Yet another Feeping Creaturism. -- pyotr filipivich Next month's Panel: Graft - Boon or blessing? |
#13
|
|||
|
|||
how to get the title into task manger 'window'?
On 9/19/2018 5:19 PM, VanguardLH wrote:
Zaidy036 wrote: I use Nircmd to rename, change size, and change position of CMD windows: START "" /WAIT ... ^___ Could've set the new window's title right there. Because you did not use the /b switch (to reuse the current shell), the program loads in a new shell (which opens a new console window). You can use the title parameter of the 'start' command to specify the title for that new window. The /wait switch means leaving open the console window for the current shell until the called program/script exits in the other window. You'll end up with two windows open: for the console shell where you ran 'start' and the one for within which the program/script runs. Using Nircmd to change CMD window size and position would then require a separate CMDs so this works fine for me especially since it does NOT open a second CMD window. -- Zaidy036 |
#14
|
|||
|
|||
how to get the title into task manger 'window'?
Zaidy036 wrote:
On 9/19/2018 5:19 PM, VanguardLH wrote: Zaidy036 wrote: I use Nircmd to rename, change size, and change position of CMD windows: START "" /WAIT ... ^___ Could've set the new window's title right there. Because you did not use the /b switch (to reuse the current shell), the program loads in a new shell (which opens a new console window). You can use the title parameter of the 'start' command to specify the title for that new window. The /wait switch means leaving open the console window for the current shell until the called program/script exits in the other window. You'll end up with two windows open: for the console shell where you ran 'start' and the one for within which the program/script runs. Using Nircmd to change CMD window size and position would then require a separate CMDs so this works fine for me especially since it does NOT open a second CMD window. I like Kleebauer's solution best: just use the 'title' command within the batch file. However, doesn't do anything regarding positioning of the window. |
#15
|
|||
|
|||
how to get the title into task manger 'window'?
On 19.09.2018 22:52, Zaidy036 wrote:
I use Nircmd to rename, change size, and change position of CMD windows: :: Change CMD Window title, size, and position :: ================================================== ============ To rename the title you can use the "title" command: title mybat To change the size you can use the "mode" command: mode con cols=101 lines=30 To change the position, you can embed a small binary within the batch. This way the batch runs an any system and doesn't depend on an external program. @echo off :: winpos.exe: specify the position for the Command Window :: :: usage: winpos [T] xpos ypos :: if T is given, the window becomes TOPMOST :: example: winpos - new position 0,0 :: winpos 100 200 - new position 100,200 :: winpos T 200 - new position 200,0 TOPMOST certutil -f -decode %~f0 winpos.exenul cls echo CMD Window is now at position 100 100 echo. winpos.exe 100 100 pause echo. echo CMD Window is now at position 200 -30 and TOPMOST echo it can't be hidden behind an other window echo and it is more complicated to move or close it with the mouse echo. winpos.exe T 200 -30 pause echo. echo CMD Window is now at position 100 0 and no more TOPMOST winpos.exe 100 pause echo. del winpos.exe goto :eof -----BEGIN CERTIFICATE----- TVpgAQEAAAAEAAAA//8AAGABAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAAAAoAAAAA4fug4AtAnNIbgBTM0hTmljZSB0by BtZWV0IHNvbWVi b2R5IHdobyBpcyBzdGlsbCB1c2luZyBET1MsDQpidXQgdGhpcy Bwcm9ncmFtIHJl cXVpcmVzIFdpbjMyLg0KJFBFAABMAQEAUHmlNgAAAAAAAAAA4A APAQsBBQwAAgAA AAAAAAAAAADKEAAAABAAAAAgAAAAAEAAABAAAAACAAAFAAAAAA AAAAUAAAAAAAAA ACAAAAACAAAAAAAAAwAAAAAAEAAAEAAAAAAQAAAQAAAAAAAAEA AAAAAAAAAAAAAA GBAAADwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAQAAAYAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAALnRleHQAAABkAQAAAB AAAAACAAAAAgAA AAAAAAAAAAAAAAAAIAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABoEAAAAA AAAJYQAACoEAAA vBAAAAAAAABgEAAAAAAAAAAAAABUEAAAABAAAIYQAAAAAAAAAA AAAHgQAAAIEAAA AAAAAAAAAAAAAAAAAAAAAAAAAABVU0VSMzIuZGxsAABoEAAAAA AAAAAAU2V0V2lu ZG93UG9zAABLRVJORUwzMi5kbGwAAJYQAACoEAAAvBAAAAAAAA AAAEdldENvbW1h bmRMaW5lQQAAAEdldENvbnNvbGVXaW5kb3cAAAAARXhpdFByb2 Nlc3MA/xUIEEAA MdJIQIA4AHQRgDgidQL30gnSde+AOCB16kAx7egrAAAAif7oJA AAAIPtAv8VDBBA AGgBAAAAagBqAFdWVVD/FQAQQABqAP8VEBBAADH/MckPthAI0nQ2QID6LXQWgPpU dQW9AQAAAIDqMHLkgPoJd9/rE0kPthAI0nQSQIDqMHIMgPoJdwdr/woB1+vnCcl0 AvffwwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAAAA AAAAAAAAAAAAAAAAAAAAAA== -----END CERTIFICATE----- |
Thread Tools | |
Display Modes | Rate This Thread |
|
|