2

I'm having an issue with Visual Studio 2022. After using template to create a class/interface the code is generated with an error. There is no whitespace between "internal" and "class". The problem is hapenning with one particular project. When I createad a file in a new project the problem did't occur. Did anyone experience this issue as well and has a solution?

Screenshot - "internalclass"

EDIT:

Fixed using solution from this post.

Nereval
  • 21
  • 4
  • 1
    Does this help you: https://learn.microsoft.com/en-us/visualstudio/ide/how-to-update-existing-templates?view=vs-2022 ? – Paul Karam Mar 04 '22 at 10:07
  • Haven't experienced that issue, although I've followed the article Paul gave to change mine to use the public access modifier anyway (I tend to use a lot cross-project interfaces). – Andrew Corrigan Mar 04 '22 at 10:10
  • Each of the folders in the location %USERPROFILE%\Documents\Visual Studio \Templates\ProjectTemplates is empty, therefore I can't modify any. I'll try to create a new template, maybe that will help. – Nereval Mar 04 '22 at 10:15
  • The issue is only happening in the particular project. When created a new project the problem was gone. – Nereval Mar 04 '22 at 10:20

0 Answers0