Yes and no. You can create custom item templates that you can add to any project. Those templates can be full source files with some value substituted. But you are limited to a few sets of possible values. Read more about custom item templates here.
Within an arbitrary source file you can request the editor to auto-generate a file header if you have an .editorconfig
file set up. However I don't know that it supports variable replacement. Refer to this article on how to do that.
If you need something more advanced then the editor supports VS snippets. These allow you to type in something and generate some code from that. They also support limited variable expansion. Refer to this article on how to use code snippets.
If none of these work for you then you'll need to look into a third party extension. I personally use DevExpress CodeRush for this because of the templating support it has. It allows me to type in a shortcut and auto-generate code that is as simple or complex as I need. It is advanced enough that it can even use the styling rules defined in the editor to get things to work. Getting the template working can be a little trial and error but once it works it is awesome. For example I have a template that auto-generates my company's copyright header whenever I type in /copy
provided I'm on a blank line. And it generates the copyright header with the current year and my name if I want. I have other templates as well. For example I can type in /x
above a member but inside a doccomment and it auto-generates an exception tag for me. If I'm on a property then the exception tag is generated differently than on a method. You can get as simple or as complex as you want. However third party extensions do cost money but I think it is worth the productivity gain.