vsx

How to create a VisualStudio item template that does not offer numbered file names by default

三世轮回 提交于 2020-06-27 13:07:49
问题 If I create an item template with default name foo.txt , Visual Studio by default offers the name foo1.txt in the add new dialog, even if there is no foo.txt in the folder. This is normally fine, but I would need to create an item template, that does not offer a "1" suffix for the file name by default, exactly like the App.config template behaves. I have checked the App.vstemplate file in the VS2019 installation, but I don't see any special setting that would cause this behavior. Sample: <

How to create a VisualStudio item template that does not offer numbered file names by default

一笑奈何 提交于 2020-06-27 13:07:30
问题 If I create an item template with default name foo.txt , Visual Studio by default offers the name foo1.txt in the add new dialog, even if there is no foo.txt in the folder. This is normally fine, but I would need to create an item template, that does not offer a "1" suffix for the file name by default, exactly like the App.config template behaves. I have checked the App.vstemplate file in the VS2019 installation, but I don't see any special setting that would cause this behavior. Sample: <

Getting a SemanticModel of a cshtml file?

瘦欲@ 提交于 2020-05-12 22:33:21
问题 I'd like to use Roslyn to analyze semantic information within the context of a block of C# code inside a Razor View. Is there any way (within Visual Studio 2015, or even in a unit test) to get the SemanticModel that represents this code? 回答1: Razor files contain a C# projection buffer with the generated C# code (including the parts that you don't write yourself). This buffer has full Roslyn services and is exactly what you're looking for. You need to walk through the TextView's BufferGraph

Getting a SemanticModel of a cshtml file?

Deadly 提交于 2020-05-12 22:23:54
问题 I'd like to use Roslyn to analyze semantic information within the context of a block of C# code inside a Razor View. Is there any way (within Visual Studio 2015, or even in a unit test) to get the SemanticModel that represents this code? 回答1: Razor files contain a C# projection buffer with the generated C# code (including the parts that you don't write yourself). This buffer has full Roslyn services and is exactly what you're looking for. You need to walk through the TextView's BufferGraph

Getting a SemanticModel of a cshtml file?

岁酱吖の 提交于 2020-05-12 22:23:45
问题 I'd like to use Roslyn to analyze semantic information within the context of a block of C# code inside a Razor View. Is there any way (within Visual Studio 2015, or even in a unit test) to get the SemanticModel that represents this code? 回答1: Razor files contain a C# projection buffer with the generated C# code (including the parts that you don't write yourself). This buffer has full Roslyn services and is exactly what you're looking for. You need to walk through the TextView's BufferGraph

Getting a SemanticModel of a cshtml file?

空扰寡人 提交于 2020-05-12 22:23:27
问题 I'd like to use Roslyn to analyze semantic information within the context of a block of C# code inside a Razor View. Is there any way (within Visual Studio 2015, or even in a unit test) to get the SemanticModel that represents this code? 回答1: Razor files contain a C# projection buffer with the generated C# code (including the parts that you don't write yourself). This buffer has full Roslyn services and is exactly what you're looking for. You need to walk through the TextView's BufferGraph

How to get project folder on a VSIX project

倾然丶 夕夏残阳落幕 提交于 2020-02-25 03:54:08
问题 I'm developing an extension for VS2015 and i need to get the project folder of the opened solution. And then find the bin folder to get the output DLL. All this because i need to instantiate a class from the output DLL using reflection. I tried to get some information from msdn but it's difficult to me understand. Is there a way to do this? Thanks in advance 回答1: You could try something like this... Find the project file of interest (maybe the startup project), or let the user select it. The

VSIX Extension uses 3rd party DLLs unable to load one of the dependency

ぐ巨炮叔叔 提交于 2020-02-24 12:09:30
问题 I am developing an extension to VS2013. Since it will be installed through MSI, I am changing the base directory to installation folder using ProvideBindingPath attribute to package class. But the 3rd party dll reference which will be loaded in runtime is not picking dll from the probed path. Its always looking into Visual studio devenv.exe folder. Is there any way to force the dll to look into my installation folder. using MD=Microsoft.VisualStudio.Modeling.Shell; MD.ProvideBindingPath

VSIX Extension uses 3rd party DLLs unable to load one of the dependency

血红的双手。 提交于 2020-02-24 12:08:59
问题 I am developing an extension to VS2013. Since it will be installed through MSI, I am changing the base directory to installation folder using ProvideBindingPath attribute to package class. But the 3rd party dll reference which will be loaded in runtime is not picking dll from the probed path. Its always looking into Visual studio devenv.exe folder. Is there any way to force the dll to look into my installation folder. using MD=Microsoft.VisualStudio.Modeling.Shell; MD.ProvideBindingPath

VS2010: VSIX installation doesn't deploy item templates inside it

倾然丶 夕夏残阳落幕 提交于 2020-01-24 20:15:11
问题 Given demo solution with two VSX-projects: 1. Add New Project -> Extensibility -> Item Template - "ItemTemplate1" 2. Add New Project -> Extensibility -> VSIX Project - "VSIXProject1" I did no changes in "ItemTemplate1", so it constains default item template (ItemTemplate1.vstemplate): <VSTemplate Version="3.0.0" Type="Item" xmlns="http://schemas.microsoft.com/developer/vstemplate/2005"> <TemplateData> <Name>ItemTemplate1</Name> <Description><No description available></Description> <Icon