Is there a way to save all unsaved documents (files with the '*' in the VS editor tab) using DTE or something else in a VSIX command?
I'm creating a command that reads the current document's syntax tree, but I cannot access unsaved changes made to that document, so I wish to save all files open in the editor before running my code.
DTE.ExecuteCommand("File.SaveAll");
This will execute the Save All command, as if you executed it from GUI: