Changing Settings File Directly Notepad new Version Warn
Moderators: Hacker, petermad, Stefan2, white
- I-Vladimir
- Junior Member
- Posts: 29
- Joined: 2012-09-26, 15:18 UTC
Changing Settings File Directly Notepad new Version Warn
When I open ini files directly, each Notepad window displays a yellow box at the top: A new version of Notepad is available. Launch.
Launch button switches Notepad to UWP version. I assume command line can be changed to use an app registered for ini extension or use txt extension if nothing registered for ini.
OS Version - Microsoft Windows [Version 10.0.22621.1702]
Launch button switches Notepad to UWP version. I assume command line can be changed to use an app registered for ini extension or use txt extension if nothing registered for ini.
OS Version - Microsoft Windows [Version 10.0.22621.1702]
Re: Changing Settings File Directly Notepad new Version Warn
This has nothing to do with file extensions, and it's not a bug either. TC calls %SystemRoot%\system32\notepad.exe. This is hardcoded and can't be changed. It has been discussed for many years that TC should call the editor set in its options instead. Until this is implemented one can a workaround. Put the following on a button or TC's start menu.
Command:
Parameters:The execution via cmd.exe ensures that environment variables are expanded. This way it works properly even if the editor can't understand them.
An UWP app can also be used. There's a thread with some PowerShell code I posted how the necessary information can be determined to start the desired app.
Regards
Dalai
Command:
Code: Select all
cmd.exe
Code: Select all
/c "start "" "C:\your_favorite_editor.exe" "%%COMMANDER_INI%%" "%%COMMANDER_PATH%%\wcx_ftp.ini""
An UWP app can also be used. There's a thread with some PowerShell code I posted how the necessary information can be determined to start the desired app.
Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64
Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64
Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
- I-Vladimir
- Junior Member
- Posts: 29
- Joined: 2012-09-26, 15:18 UTC
Re: Changing Settings File Directly Notepad new Version Warn
That is what I got calling FindExecutable("wincmd.ini", "c:\Program Files\totalcmd\")
C:\Program Files\WindowsApps\Microsoft.WindowsNotepad_11.2304.26.0_x64__8wekyb3d8bbwe\Notepad\Notepad.exe
So WinAPI call returns UWP app exe name
C:\Program Files\WindowsApps\Microsoft.WindowsNotepad_11.2304.26.0_x64__8wekyb3d8bbwe\Notepad\Notepad.exe
So WinAPI call returns UWP app exe name
Re: Changing Settings File Directly Notepad new Version Warn
I use NotePad Replacer from
https://www.binaryfortress.com/NotepadReplacer/
It replaces all calls to NotePad with any other editor, in my case PSPad.
This works with the hardcoded NotePad call in TC and from any other tool.
https://www.binaryfortress.com/NotepadReplacer/
It replaces all calls to NotePad with any other editor, in my case PSPad.
This works with the hardcoded NotePad call in TC and from any other tool.
Windows 11 Home, Version 24H2 (OS Build 26100.4061)
TC 11.55 RC2 x64 / x86
Everything 1.5.0.1391a (x64), Everything Toolbar 1.5.2.0, Listary Pro 6.3.2.88
QAP 11.6.4.4 x64
TC 11.55 RC2 x64 / x86
Everything 1.5.0.1391a (x64), Everything Toolbar 1.5.2.0, Listary Pro 6.3.2.88
QAP 11.6.4.4 x64
Re: Changing Settings File Directly Notepad new Version Warn
BTW, in TC 11 you can use %|COMMANDER_INI| to insert the actual value of the variable, withoug having to rely on the started program to expand it.Dalai wrote: 2023-06-15, 18:01 UTCThe execution via cmd.exe ensures that environment variables are expanded. This way it works properly even if the editor can't understand them.
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
Using TC 11.03 / Win10 x64
Using TC 11.03 / Win10 x64
- ghisler(Author)
- Site Admin
- Posts: 50532
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: Changing Settings File Directly Notepad new Version Warn
This isn't a bug in Total Commander, I just call the standard notepad.exe here.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Re: Changing Settings File Directly Notepad new Version Warn
Therefore I use custom commands (usercmd.ini) for that (to open ini(s) in the associated editor).
For instance:
for the main .ini:
for all the .ini(s) which are not related to plugins:
for all the .ini(s) which are related to plugins:
and so on
For instance:
for the main .ini:
Code: Select all
[em_ini_edit]
cmd=%commander_path%\wincmd.ini
Code: Select all
[em_ini_edit_noplugs]
cmd=Powershell -ExecutionPolicy Bypass
param=gci "$env:commander_path" -filter *.ini|Where-Object {$_.Name -notmatch 'plug'}|foreach-Object -process {ii $_.fullname}
Code: Select all
[em_ini_edit_plugs]
cmd=Powershell -ExecutionPolicy Bypass
param=gci "$env:commander_path" -filter *.ini|Where-Object {$_.Name -match 'plug'}|foreach-Object -process {ii $_.fullname}
#278521 User License
Total Commander [always the latest version, including betas] x86/x64 on Win10 x64/Android 10/15
Total Commander [always the latest version, including betas] x86/x64 on Win10 x64/Android 10/15