Giter VIP home page Giter VIP logo

vssdk-extensibility-samples's Introduction

Visual Studio Extensibility Samples

Join the chat at https://gitter.im/Microsoft/extendvs Build status

These samples demonstrate how to customize the appearance and behavior of the Visual Studio IDE and editor. The following are some of the ways in which you can extend Visual Studio:

  • Add commands, buttons, menus, and other UI elements to the IDE
  • Add tool windows for new functionality
  • Add support in Visual Studio for new programming languages
  • Add refactoring or language analyzers to fix and improve code
  • Add a custom project type or new project or item templates

If you've never written a Visual Studio extension before, we've got some great resources to get started.

Getting started

  1. Clone the repo to download all samples (How to)

    git clone https://github.com/Microsoft/VSSDK-Extensibility-Samples.git

  2. Read the readme included with each sample and try it in Visual Studio

Other extensibility samples

  • If you're building XAML controls for UWP that are deployed as NuGet packages, you can add design-time support so that they automatically appear in the toolbox when they are referenced. This sample is in the NuGet repo.

  • We have separate repositories and documentation for writing extensions for other members of the Visual Studio family:

Other useful resources

  • Publish your completed extension to the Visual Studio Marketplace, which provides a convenient place for developers to find and install your extension.

  • Join the Visual Studio Partner Program for free to get access to dedicated resources to support you as an extension publisher.

  • For details on how to create user experiences that are seamless and consistent within the IDE, visit the Visual Studio User Experience Guidelines. You will also find information about the common user models and interaction patterns that are used and how you can utilize them as well.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

Thank you for your support for Visual Studio - we're excited to see what extensions you build!

vssdk-extensibility-samples's People

Contributors

123ling avatar aarnott avatar aaronrobinsonmsft avatar adrianvmsft avatar alexeyler avatar amadeusw avatar antonellamarengo avatar bertanaygun avatar bertique avatar cathysull avatar chitrakoppolu avatar egoughnour avatar jialongcheng avatar jozefizso avatar justcla avatar lushawang avatar madskristensen avatar microsoft-github-policy-service[bot] avatar milopezc avatar mpeyrotc avatar niko999999 avatar olegtk avatar prasethu avatar selmai avatar sgreenmsft avatar shyykoserhiy avatar stephaniesu avatar timsneath avatar tinaschrepfer avatar willbrown2000 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vssdk-extensibility-samples's Issues

How could we write extensions for SSMS 2016?

No documentation is available on MSDN :(
Could you please show us some examples on writing extensions for the SQL Server Management Studio 2016?
Could we reuse the already opened connection within the extension in SSMS?

Ook language doesnt work if VS is installed in a non-default location

Installed products

  • Visual Studio: Community 2015 update 3

Description

When you follow the directions and F5 or start debugging, an error shows up

visual studio cannot start debugging because the debug target c:\program files\something something\ide\devenv.exe is missing

Steps to recreate

  1. Install VS to a D or E drive
  2. Git Ook
  3. F5 Ook
  4. Scratch head, saying ook?
  5. Ook!

Current behavior

Error message in description

Expected behavior

It runs

To fix this for yourself, open the project properties and go to the debug tab. There is a Start Action that has the start external program value set incorrectly (for some). Change that to where you have vs installed.

LSP client fails to initialize if the "Visual C++ package" isn't installed.

Installed products

  • Visual Studio: Enterprise 2017 Preview

Description

LSP client fails to initialize if the "Visual C++ package" isn't installed. Whether the current behaviour is the correct behaviour, and more requirements should be listed on readme.md, or a functional issue is not clear to me.

Steps to recreate

  1. Install a fresh VS 2017 Preview
  2. Install the Language Server Protocol Client Preview package for VS 2017 Preview
  3. Open the solution VSSDK-Extensibility-Samples/blob/master/LanguageServerProtocol/MockLanguage.sln
  4. Set default project to MockLanguageExtension
  5. Press f5 to start debugging
  6. In the newly opened instance of VS 2017 Preview, open one of the .foo files

Current behavior

An error is displayed that the Visual C++ package failed to load
ActivityLog.xml contains the following entries:

  <entry>
    <record>2176</record>
    <time>2018/03/19 10:34:17.814</time>
    <type>Error</type>
    <source>VisualStudio</source>
    <description>SetSite failed for package [Visual C++ Package](null)</description>
    <guid>{1B027A40-8F43-11D0-8D11-00A0C91BC942}</guid>
    <hr>80070002</hr>
    <errorinfo></errorinfo>
  </entry>
  <entry>
    <record>2177</record>
    <time>2018/03/19 10:34:19.190</time>
    <type>Error</type>
    <source>VisualStudio</source>
    <description>End package load [Visual C++ Package]</description>
    <guid>{1B027A40-8F43-11D0-8D11-00A0C91BC942}</guid>
    <hr>80070002</hr>
    <errorinfo></errorinfo>
  </entry>

Expected behavior

The file should open, and the LSP server and LSP client should start

WPFDesigner_XML : ViewModel.GetXmlLanguageService return null

Hi,

Installed products

  • Visual Studio: Professional 2017 Update 2 (15.2)

Description

I cannot run the WPFDesigner_XML correctly.
When I changed a property the call of
_xmlLanguageService = Marshal.GetObjectForIUnknown(ptr) as LanguageService;
return null in ViewModel.GetXmlLanguageService method.

Thanks a lot,
Geotinc

Error in Building it

I tried to build it. Since it required the assembly Microsoft.VisualStudio.Utilities , I have referenced to it, but the following warning has been shows:

The primary reference "Microsoft.VisualStudio.Utilities, Version=15.0.0.0, could not be resolved because it was built against the ".NETFramework,Version=v4.6" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.5.2".

I am using MVS 2017. Do you know how can I reference to Microsoft.VisualStudio.Utilities 14 ?

How do you style your controls depending on the current VS theme?

The default brushes used is the blue theme. The project template created UserControl has the following as a hint, but it's still not the right color:

Background="{DynamicResource VsBrush.Window}"
Foreground="{DynamicResource VsBrush.WindowText}"

However, specifying that for every control becomes quite tedious, isn't there a better way? A "global" style binding?

I'm trying to style the Toolbar and I can't seem to change the overflow arrow's color. It's currently blue while the rest of the Toolbar uses the specified brush.

Syntax coloring for multiline comment blocks

Not an issue per-se but a question.

I have an extension for a new language that adds syntax coloring (among other features).
The problem I'm facing, I can't find good samples of it, is that in some cases I need to color many lines depending on one already processed. Think of it like the a multiline comment block in C#.

var a = 1; /* So far was valid code 
but now it is a comment
until here*/

I've been working with the IClassifier IList<ClassificationSpan> GetClassificationSpans(SnapshotSpan span) returning different classifiers, but is what I've noticed so far. If I process every line in the span I get, I can effectively color my block of comment as expected, but, it takes waaaay to long and makes the Visual Studio Editor to have jerky moves... it starts to work really slow, even scrolling in the editor get "heavy".
If, on the other way, I process just the first line in the span, I do get a fast editor, but I can't get the comment block to be painted cause I'm always processing one row at a time.

I'm looking for samples but everything I've found so far are single lines coloring. Is there a sample I can be referred to? Or maybe just a tip on how to do it?

Thanks

custom Project wizard

I intend to develop a plug-in, this plug-in is used to develop MCU procedures (such as STM32,AVR ,). I have two questions on this plug-in:

  1. When you create a new project and press the OK button, the custom project wizard windows will be display. Let the user fill in some of the necessary information.I do not know how to implement this feature, because in this GIT warehouse which did not find a similar example.
  2. When you press the Debug button, this time should be downloaded to the ELF file inside the MCU. I think I should listen Debug button's click event.

Cannot build in Missing ICO files

Installed products

  • Visual Studio: 2017 Version 15.6.4

Description

Missing ICO files that are in the dropdown

Steps to recreate

  1. Add an icon to a project
  2. Delete the icon in the file system
  3. Add another icon to your project
  4. Try to Build your project. It won't build because it can't find the ico file that you aren't even selecting!

Current behavior

Can't build the solution because of the missing ico files - that aren't even selected...

Expected behavior

Missing ico files should not stop you from building a solution.

Can I use the Image Service outside of VS Extension projects?

I don't really know if this is the best place to ask is (if there's a better place: please point me in that direction).

I stumbled upon the Image Service and was wondering if it is allowed to use it outside of VS Extensions? Can I use it in my standalone application? Can I include the standard VS icon manifest with my application?

opening `.foo` file doesn't show a language server window

Installed products

  • Visual Studio: Enterprise 2017 Preview

Description

LSP client fails to initialize if the "Visual C++ package" isn't installed. Whether the current behaviour is the correct behaviour, and more requirements should be listed on readme.md, or a functional issue is not clear to me.

Steps to recreate

  1. Install a fresh VS 2017 Preview
  2. Install the Language Server Protocol Client Preview package for VS 2017 Preview
  3. Open the solution VSSDK-Extensibility-Samples/blob/master/LanguageServerProtocol/MockLanguage.sln
  4. Install C++ workloads
  5. Set default project to MockLanguageExtension
  6. Press f5 to start debugging
  7. In the newly opened instance of VS 2017 Preview, open one of the .foo files

Current behavior

The file opens in a text editor. Nothing else happens.

Expected behavior

The mock language server UI appears.

All reference are broken by opening this solution with VS2015 Update1

As subject
All reference are broken by opening this solution with VS2015 Update1 and apparently no way of restoring missing packages:
NuGet Package restore failed for project WPFDesigner_XML: Unable to find version '14.0.22823-RC' of package 'Microsoft.VisualStudio.Shell.14.0'
untitled

Doesn't work with .NET Standard Libraries.

Installed products

  • Visual Studio: Visual Studio 2017 15.2

Description

This code generation example works with a standard .Net 4.5, .Net 4.6 library and PCL library project, but doesn't work with a .NETStandard library project.

Steps to recreate

  1. Create a blank solution.
  2. Create a .NETStandard Library
  3. Create a resource.
  4. Replace ResXResourceGenerator with XmlFileGenerator
  5. Code is not generated, no error message.

Current behavior

The code generator works with old .NET and PLC libraries.

Expected behavior

It should work with a .NET Standard library.

Display markers in Visual Studio Solution Explorer

Target Versions

  • Visual Studio: 2015 /2017

Question

I need to display some markers next to files in VS solution explorer (As in the image link below). I have gone through the VS SDK documentation and there are no references in this specific requirement. Is this possible in current SDK?

Thanks-

Image

SCC Sample Won't Run A Second Time

Installed products

  • Visual Studio 2017 Professional (15.2, 26430.6)

Description

The basic SCC sample works the first time I run it, but the second time I try, no tool window pops up, and I can't see anything under "Tools->Options, Source Control->Plug-in Selection" for the SCC pluigin anymore.

Steps to recreate

  1. Copy the Basic_Source_Control_Provider directory to a new directory
  2. Open the SLN file
  3. Press F5
  4. The tool window will pop up fine, if you go to Tools -> Options, SOurce Control, you have the custom section and the drop down is correct - so far so good.
  5. Close all dialogs, and close down the hosted VS
  6. In the VS with the BasicSCCProvider.sln, press F5 again
  7. No tool window pops up, and going to Tools->Options, Source Control shows no custom windows, and the custom provider is missing from the list.

Current behavior

Covered above.

Expected behavior

To be able to repeatedly iterate without having to copy/paste the project each time.

OptionPageCS project doesn't build because of a missing file

Installed products

  • Visual Studio: Enterprise 2017 Version 15.3.5

Description

OptionPageCS project doesn't build because of a missing file.

Steps to recreate

  1. Open OptionPageCS project
  2. Try to build it.

Current behavior

1>------ Build started: Project: OptionsPageCS, Configuration: Debug Any CPU ------
1>C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Microsoft.WinFx.targets(711,5): error BG1002: File 'Example.OptionsPage2.png' cannot be found.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

Expected behavior

Build succeeds.

Lightbulb sample will not run

Installed products

  • Visual Studio: professional 2017 - v15.6.4

Description

The lightbulbs never show up

Steps to recreate

  1. Clone the repo
  2. Run the Lightbulb sample
  3. No lightbulbs display in text files

Current behavior

It is supposed to show you how to display lightbulb helpers, but the sample doesn't work at all.

Expected behavior

It should show the lightbulbs in txt files so we can use this example to help build extensions

Ook language integration parsed as XML

Installed products

  • Visual Studio: 2013/2015

Description

If a source file starts with "" , Visual Studio thinks it's an XML file and there is no syntax highlight nor IntelliSense.

Steps to recreate

  1. Add to the start of the test.ook file
  2. Build and extension and test it with the newly created test.ook file

WPFDesigner_XML - no xml declaration casues FormatBuffer exception

I have attempted to use WPFDesigner_XML sample to create my own editor.

Edit as per below comment: However for some reason I can't fathom, I have noticed that when the xml file does not have an xml declaration at the top, then the method that Format's the buffer, and specifically the call to ReformatSpan throw's an exception Value does not fall within the expected range

image

How do we work around the xml file not having an xml declaration?

Question for single file generator extension

For the single file generator extension, why do you not start with the implementation of BaseCodeGeneratorWithSite in Microsoft.VisualStudio.TextTemplating.VSHost.15.0 assembly?

Also your sample doesn't register the file extension for our custom tool, an extra attribute is necessary for that to occur:
[CodeGeneratorRegistration(typeof(XmlClassGenerator), "XmlClassGenerator", vsContextGuids.vsContextGuidVCSProject, GeneratesDesignTimeSource = true, GeneratorRegKeyName = ".xml")]

Could you provide a sample for resources localization?

Visual Studio: 2017/2015

Description

I have read Localizing Menu Commands
about how to localize menu/command,

Steps to recreate

  1. Create new VSIX project
  2. Add CustomToolWindow based on VS template.
  3. do each instructions based on Menu Commands

Current behavior

project can be compiled, but when debug/execute it, System.IO.IOException will be thrown, "can't find resource toolwindow1control.xaml"

Expected behavior

please provide correct instructions in ms doc or samples ..

Intellisense in the Ook_Language_Integration sample

The sample "Ook_Language_Integration" has problems with the intellisense when the cursor is placed in a virtual space. The triggerPoint that is obtained with session.GetTriggerPoint(snapshot) is set back to the non-virtual position before the cursor (and as far as I know, SnapshotPoint can only represent non-virtual positions) which leads to a wrongly positioned intellisense window:
screenshot

I have the same problem in my own language integration extension and don't know how to fix this.

Open a solution item in a new tab group in VSIX (visual studio extension)

I want to write an extension to open automatically the CSS file related to a LESS or SASS file in a new vertical tab group. It should create a new tab group if there is not any or use it if there is an existing tab group.


    void DoIt()
    {
        var dte2 = ((IServiceProvider)package).GetService(typeof(SDTE)) as EnvDTE80.DTE2;

        var currentActiveWindow = dte2.ActiveWindow;

        if (!IsItALessOrSassFile())
            return;

        var item = dte2.Solution.FindProjectItem(GetTheCssFileNameOfTheCurrentFile());
        item = item ?? throw new Exception();

        if (item.IsOpen)
            return;

        var window = item.Open();

        // I could not find any property or method to force the window to be opened in a new tab group.

        window.Activate();

        window.Document.ReadOnly = true;

        currentActiveWindow.Activate();            
    }

I mean the result should be somthing like this.

ksgcr

AsyncPackage example

I'm not finding barely any docs or examples on the new async package changes (speedy startup). It would be great having an example that show cases this.

Provide example or details on WFP control styling to follow VS

I'm struggling on styling controls for an extension I'm working so they follow exactly what is in VS...
For example: how do I style properly this Action control on Pending Changes view of Team Explorer?

image

I think the examples should provide more comprehensive styling examples...
Anyways: thanks for what is available now. 👍

Visual Studio intercepts my InputBindings defined in XAML

It seems that Visual Studio intercepts InputBindings, if they're mapped in Visual Studio. I've added two mappings to Ctrl+R and Ctrl+S (Reload and Save). I've tried adding them to the UserControl and to a child element; in both scenarios VS intercepts.

It works if I use a key combination that isn't used by VS.

So, how can my Extension/UserControl get the input instead/first?

Bug in Editor With Toolbox Sample When Rename File

  1. Run the Editor With Toolbox Sample in Debug mode
  2. From Experimental Instance, create a new project (e.g. c# winforms), or just open an existing one
  3. File > New > File > Editor With Toolbox - C# Sample > create new instance of custom editor
  4. Save the file in the project folder and add it to the project in solution explorer
  5. CLOSE THE CUSTOM EDITOR designer if it's open (e.g. TbxFile1.tbx)
  6. Reopen it
  7. WHILE OPEN, RENAME THE FILE in solution explorer (e.g. change to XXX.tbx)
  8. Type some new lines of text
  9. Save the file
  10. Close it and reopen it.
  11. New text is not there. If you look in the project folder, you will see it saved the file using the old file name (TbxFile1.tbx)

Also went through the steps in this youtube video: https://youtu.be/pY5uitIIbkA

Extensibility > Toolbox is empty when targeting .NET Framework 4.0

Installed products

  • Visual Studio: Visual Studio Enterprise 2017 15.6.1

Description

After creating new VSIX Project and changing target framework to .NET Framework 4.0 I'm unable to add new item to project. After right clicking on project name, selecting Add > New item I get this dialog (no items to select from):
snap 2018-04-06 at 13 58 02

Steps to recreate

As described above

  1. Create VSIX project
  2. Change target framework to .NET Framework 4.0 (in project properties, application, target framework)
  3. Try to add Toolbox Control

Current behavior

I can't add Toolbox Control when targeting .NET Framework 4.0.
The only way to get this working is to change target framework to 4.5 (after doing that I see Windows Forms Toolbox Control), but I must target 4.0.

Expected behavior

I want to use Visual Studio 2017 to create VSIX with my custom controls that target .NET 4.0.
I have some legacy projects (targeting .NET 4.0) in which I want to use my custom controls. I need VSIX to install them into Toolbox.

Stop receiving events when toolbar is hidden

Installed products

  • Visual Studio 2017 15.6.1

Description

Toolbar with drop down combo still receives advised events after toolbar is hidden.

Steps to recreate

  1. Use Drop Down Combo from https://github.com/Microsoft/VSSDK-Extensibility-Samples/tree/master/Combo_Box sample
  2. Use IVsMonitorSelection.AdviseSelectionEvents()
  3. Hide the toolbar.

Current behavior

I could not find any event to be notified when toolbar is hidden/shown so could not stop receiving those events.

Expected behavior

Advise/Unadvise selection events when toolbar is hidden or shown.

Does not build out of the box on vs2017

Installed products

  • Visual Studio: [example Professional 2017]

Description

After project upgrade/migration, I build the solution and get an error. I dont have any older Visual Studio versions installed. I have VS2017 installed on the D:\vs2017
I tried upgrading the entire project to the 15.0 version of this dll but I get tons of other problems with that approach.

Steps to recreate

  1. Load solution in vs2017
  2. Build solution

2017-04-28 19_42_45-ooklanguage - microsoft visual studio

Sample Request - Capturing key strokes in the solution explorer

Hi,
I know there is a sample that deals with extending the solution explorer by adding a custom button here https://msdn.microsoft.com/en-us/library/bb166773.aspx.

What I haven't been able to find (perhaps it's my own poor googling skills) is something that captures keystrokes in the solution explorer. I believe the "Microsoft.VisualStudio.Text.Edtior.KeyProcessor" only captures keystrokes in the actual text window. It doesn't seem to be firing when I type keys with the solution explorer selected.

Basically, what I am trying to do is, if the user presses "j" I want to select the file above the currently selected file (The equivalent of pressing the Up-Arrow key on the keyboard when the solution explorer is active and a file is selected) and when the user presses "k" I want to select the file below the currently selected file (The equivalent of pressing the Down-Arrow key on the keyboard when the solution explorer is active and a file is selected).

I would be very grateful if you could point me to a sample that would do something similar.

WPFDesigner_XML project does not work with provided templates out of box (NullReferenceException)

Installed products

  • Visual Studio 2017 Enterprise Version 15.3.5

Description

Cannot run WPFDesigner_XML with sample template out of box.

Steps to recreate

  1. Download samples
  2. Open WPFDesigner_XML solution in Visual Studio 2017
  3. Compile and debug (opens experimental instance)
  4. Open any of the two files in the TestTemplates folder

Current behavior

Object reference not set to and instance of an object is encountered because the following line on 151 of VsDesignerControl.xaml results in es being nothing.

XmlEditorService es = GetService(typeof(XmlEditorService)) as XmlEditorService;

IronPythonStudio-Integrated has missing files

The project currently doesn't build due to a missing project file for 'IronPython.EditorExtensions'.

There are also numerous files using types from the IronPython.Hosting namespace, but I cannot find any types defined in that namespace.

Generator Sample: Custom Tool not registering

I just cloned the generator sample, followed the steps in the README but in the launched VS instance I always get the warning that the Custom Tool is "not on the system". Any ideas what I am doing wrong?

WPFDesigner_XML example doesn't work in VS 2017 (Community)

Installed products

  • Visual Studio: Community 2017 (15.1)

Description

I try running the WPFDesigner_XML example in Visual Studio 2017. However I am not able to run this sample. After changing the .NET version and adding prerequisites to the vsix manifest, I get a build error on the reference Microsoft.VisualStudio.XmlEditor (it cannot find this reference).

I don't find this assembly anywhere in "Add Reference" window nor on Nuget.

version of referenced assemblies

  • Visual Studio 15.5.6

Description

Inside a DeployProvider I'm using this to get the version of the referenced assemblies:
reference.Metadata.GetEvaluatedPropertyValueAsync("Version") being reference an IAssemblyReference
this used to work a few versions back, but now it returns an empty string... anyone know if this has changed ?

Current behavior

The above is returning an empty string.

Expected behavior

Should be returning the version information in the appropriate format: "1.2.3.4"

Menu_And_Commands sample has incorrectly named file Example.MenusAndCommands.png

Installed products

  • Visual Studio Community 2017 Version 15.3.5

Description

The Menu_And_Commands sample has an incorrectly named file:
Example.MenusAndCommands.png
Should be:
Example.MenuAndCommands.png (singular 'Menu' not 'Menus')

Steps to recreate

Clone sample and build.

Current behavior

Build fails with: "Could not copy the file "C:\Source\VSSDK-Extensibility-Samples\Menu_And_Commands\C#\Example.MenuAndCommands.png" because it was not found."

Expected behavior

Sample should build correctly.

Notes

The solution built after I renamed the file as described above.

"GetDeploymentPathFromVsixManifest" task failed unexpectedly, cannot debug sample

Installed products

  • Visual Studio: Enterprise 2017 15.5.3

Description

Trying to debug the TypingSpeed sample results in the following error:

error MSB4018: The "GetDeploymentPathFromVsixManifest" task failed unexpectedly.
error MSB4018: System.ArgumentNullException: Value cannot be null.
error MSB4018: Parameter name: path1
error MSB4018:    at System.IO.Path.Combine(String path1, String path2)
error MSB4018:    at Microsoft.VsSDK.Build.Tasks.ExtensionManagerUtilities.GetSettingsManagerForDevenv(String rootSuffix)
error MSB4018:    at Microsoft.VsSDK.Build.Tasks.GetDeploymentPathFromVsixManifest.Execute()
error MSB4018:    at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
error MSB4018:    at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__26.MoveNext()

Steps to recreate

  1. Download the samples .zip file and extract the TypingSpeed sample.
  2. Double-click the .sln file to open the solution.
  3. Hit F5 to build and start debugging the sample extension.

Current behavior

I get the error above and am unable to debug the sample extension.

Expected behavior

It should launch the experimental VS instance with the sample extension installed and the debugger attached.

Other Info

  • The "Start external program" path under the Debug settings is "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\devenv.exe" which I am certain is correct.
  • If I uncheck the "Deploy VSIX content to experimental instance for debugging" option under the VSIX settings then the build succeeds, but I am still unable to debug the sample.

No .csproj file for "Highlight Word" .sln

Installed products

  • Visual Studio 2015

Description

.csproj file is missing, can't load the solution properly

Steps to recreate

  1. Load .sln file into visual studio
  2. Read Output Window

Current behavior

Solution becomes unavailable

Expected behavior

Load the solution file without any errors and be easily built.

how can i get default language services in VSIXProject?

Installed products

Visual Studio 2017
VSSDK

Description

I am developing a VSIXProject for my assembly.I want to highlight the function my assembly implement and show a tooltip when mouse hover. And search all references of my assembly from solution.
Can i get code references,namespace,classname or other judgment basis from IQuickInfoSource.AugmentQuickInfoSession and ITagger.GetTags?
Is there any service could achieve my require?
How to import services in those case?
Thanks a lot.

WPFDesigner_XML ProvideXmlEditorChooserDesignerView and namespaces

I am running the WPFDesigner_XML sample (thank you for this)

I was looking at the ProvideXmlEditorChooserDesignerView attribute which is placed above the VsPackage

The xml I would like to register the xmlchooser for, is in a .dnn file, and has no xml namespace.

So I did this:

    [ProvideXmlEditorChooserDesignerView("DnnManifest", "dnn", LogicalViewID.Designer, 0x60,
        DesignerLogicalViewEditor = typeof(EditorFactory), Namespace = "", MatchExtensionAndNamespace = true)]

However, the XmlChooser then fails to open up, can you verify whether Namespace = "" works to specify xml that's not in any namespace?

When I used MatchExtensionAndNamespace=false - this had the side effect that my designer was being invoked for non ".dnn" files which has confused me.

To workaround this at present I am now making up a fake namespace and using MatchExtensionAndNamespace=false. That way the namespace that it matches on is not used by anything else so essentially that has the side effect of just matching on the ".dnn" file extension which is what I want.

[ProvideXmlEditorChooserDesignerView("DnnManifest", "dnn", LogicalViewID.Designer, 0x60,
        DesignerLogicalViewEditor = typeof(EditorFactory), Namespace = "http://doesntexist", MatchExtensionAndNamespace = false)]

Single File Generator for Python projects

Installed products

  • Visual Studio: Professional 2017 Update 3.3

Description

Is it possible to register a SingleFileGenerator VSIX for a Python project using the CodeGeneratorRegistration attribute?

Steps to recreate

  1. Create a SingleFileGenerator VSIX project
  2. [CodeGeneratorRegistration(typeof(XmlPythonClassGenerator), "Python XML Class Generator", "{888888A0-9F3D-457C-B088-3A5042F75D52}", GeneratesDesignTimeSource = true)]
  3. Run the VSIX project to start the experimental instance, create a new python project, add an XML file and set the Custom tool to XmlPythonClassGenerator

Current behavior

When saving the XML file in the Python project nothing happens.

Expected behavior

When saving the XML file in Python projects a python file is generated and added to the project

Example code similar to ImageWatch

The ImageWatch extension from VC++ Team does an amazing job, is it possible to include a simple example which does the basic thing in it? Specifically, how to get the image from a C++ variable in break mode?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.