wmic.exe /LOCALE:MS_409 /OUTPUT:stdout os get Caption > a.txt
wmic.exe /LOCALE:MS_409 /OUTPUT:stdout os get Caption | more > b.txt
06/11/2019 09:45 AM 102 a.txt
06/11/2019 09:45 AM 57 b.txt
findstr.exe -mi windows a.txt b.txt
b.txt
PATH
непричемHKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths
C:\Users\Serguei>help start
Starts a separate window to run a specified program or command.
c:\Program Files (x86)\StarDict\stardict.exe
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\stardict.exe\default
@Test(enabled = true)
public void getDir() {
JFileChooser chooser = new JFileChooser();
// chooser.setAcceptAllFileFilterUsed(false);
chooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
chooser.showSaveDialog(null);
String fileLocation = String.valueOf(chooser.getSelectedFile());
File dir = new File(fileLocation);
// readFiles(dir);
}
System.Windows.Forms.TextBox
Click
event
wmic_asciii_hack.cmd
@echo off
@REM partially based on https://superuser.com/questions/812438/combine-bat...
echo.>result.txt
echo.>>result.txt
REM result.txt has 4 bytes and NO BOM
wmic.exe /LOCALE:MS_409 /APPEND:result.txt os get Caption
findstr.exe -mi windows result.txt