Steps to Reproduce:
a.xyz)b.xyz by enter b in the save file field. (File type show as Plain Text)b.xyz. But if the destination have a .txt file, it will save as b.txt it happened on VSCode for Mac too
I meet same question when I tried to save *.in.
How can I fix it?
On a related note, I get kinda lost when saving a new empty file because I can't see which other code files are in the directory, unless I manually change the type to 'All files (*.*)'

I have same issue, and I think my issue with ti would be solved if the default was "all files" instead of plain text. Is it possible to change this setting as a user?
In my case it is a .r file I want to save, and even with extensions for R installed, the default is save as plain text (.txt)
I cannot believe this is still an issue after two years. Just took a moment to figure out why all my .py files were .py.txt.
Apparently this is disabled _by design_ inside Electron, to safeguard it from adding *.* to the file name, as can be seen in shell/browser/ui/file_dialog_win#L206.
// By default, *.* will be added to the file name if file type is "*.*". In
// Electron, we disable it to make a better experience.
// ...
for (size_t i = 0; i < filterspec.size(); ++i) {
if (std::wstring(filterspec[i].pszSpec) != L"*.*") {
// SetFileTypeIndex is regarded as one-based index.
dialog->SetFileTypeIndex(i + 1);
dialog->SetDefaultExtension(filterspec[i].pszSpec);
break;
}
}
There has to be a way though, because many other programs can do it. I'll try and test if this issue actually happens later, but I'll have to build my own Electron as well I think.
This issue seems to originate from an upstream component and is not something VSCode can fix by making a change to the code. As such, I will go ahead and close it. If you can identify the component that is causing the issue, please report it upstream:
Thanks for understanding.
Most helpful comment
I have same issue, and I think my issue with ti would be solved if the default was "all files" instead of plain text. Is it possible to change this setting as a user?
In my case it is a .r file I want to save, and even with extensions for R installed, the default is save as plain text (.txt)