Why vscode is having trouble saving a java file ? Which setting should I review?

后端 未结 1 733
感动是毒
感动是毒 2021-01-28 06:05

In vs code I hit Ctr+N and then Ctr+Shift+S,which is the sortcut for the \'save as\' option . When I try to save a file as .java , it saved automatically as class file.Of course

相关标签:
1条回答
  • 2021-01-28 06:46

    Do you act like this?

    New a file -> Save -> In the 'Save as type' drop-down list select 'Java'.

    If you look at it, you will find this: Java(*.class; *.java; *.jav; .java; .jav). And the '.class' was before the '.java', this means the file will be saved with the '.class' filename extension.

    It's caused by the VSCode, but for now, you need manually to change the filename extension when you save the file.

    0 讨论(0)
提交回复
热议问题