Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Robert Hofmann
@bert2
@yannduran I was afraid someone's gonna say that. I did a scan of all the DLL files in the VS directory to find the ones with *style.baml resources in them. I published the result as a gist. You can inspect the actual styles when you open the listed DLL with ILSpy.
Ilia Kalikin
@kalikin
Is it possible to add environment variables (e.g. COR_ENABLE_PROFILING, etc.) programmatically to a launching process from an extension? I already have a custom toolbar button and ideally the button would set the process environment and delegate to a Visual Studio run/debug action. Alternatively, extension would listen start/debug action and inject variables if a flag is set. Where should I start?
Matt Lacey
@mrlacey
@kalikin If you're launching a process (presumably one you own) can't you pass the extra details as arguments? rather than relying on "temporary" environment variables.
Or you could try something like at https://superuser.com/a/424002/257
Ilia Kalikin
@kalikin
@mrlacey By the launching process I mean the active projects' run/debug process. It should behave as it was launched by the Visual Studio, e.g. there could be user-defined arguments specified in Visual Studio Debug settings, etc.
In case of ASP.NET project it is an IIS Express process, which VS knows how to launch. Maybe I can create some custom configuration (EnvDTE.Configuration, EnvDTE.SolutionConfiguration ?) to override environment variables and use it with SolutionBuild.Debug.
Kaveesh Dashora
@kaveeshd
@madskristensen Is there any example of projection buffer available? I have a file with some metadata and text content. It is of fixed length and is present on all lines. I was thinking maybe by using projectionbuffer I can trim the metadata and only load the text content in the editor. Is it possible using projectionbuffer?
RC1844
@RC1844
How to get the content of Tooltip (CompletionSession, QuickInfoSession, SignatureHelpSession) pop-up window?
I want to modify the Tooltip content, or create a new Tooltip content based on the Tooltip content.
SidSacek
@SidSacek

Hi, I'm new to Visual Studio extensions.
What I'm curious about is this
What is the difference between these three things "Visual Studio Extensions", "Visual Studio Add-Ins", and "Visual Studio Plug-ins" ??
I heard all three of these terms being used and am wondering if they're all the same thing?

I want to extend my Visual Studio environment (not VS CODE !), and need to know which one to begin with?
What I need is to write a utility that should provide dialog boxes in Visual Studio when I have C# solutions open, and be able to interact with (modify) my open C# code.
Thanks, in advance

8 replies
007prasanth007
@007prasanth007
Hi All,
while running project in visual studio 2019 getting below error in browser page,
Could not load file or assembly 'envdte' or one of its dependencies. The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
2 replies
Anyone please help me out to resolve this
bluetarpmedia
@bluetarpmedia
Anyone played with BaseOptionModel / BaseOptionPage from
VSSDK-Extensibility-Samples/Options or Mads' projects? BaseOptionModel.Instance claims to return a singleton but the BaseOptionPage member is a separate instance. So client code using GeneralOptions.Instance returns one instance, but the dialog page used within VS Tools Options is using a different instance. They both read/write to the same ShellSettingsManager, of course, but the data loaded in the two model instances can get out-of-sync.
Yann Duran
@yannduran
@bluetarpmedia yes I'm using that code successfully. are you remembering to execute the Instance.Save method after you've made your changes to the model?
if so, under what circustrances do they get out of sync?
bluetarpmedia
@bluetarpmedia
@yannduran Yes, I called Save. If you set a breakpoint in BaseOptionModel.CreateAsync, you'll see that one instance is created from the first call to Instance (or GetLiveInstanceAsync). Then the second instance is created when VS Tools Options is first opened. (Created by BaseOptionPage ctor)
I found it easiest to repro the out-of-sync in VS 2017
Some code: Instance.SetValue, then Instance.Save
Yann Duran
@yannduran
if you're only setting one value then yes that makes good sense
bluetarpmedia
@bluetarpmedia
Then open VS Tools Options, check value. Then Cancel to close. Call that client code that changes Instance.SetValue, then go back into Tools Options and check the value again. It will be the old value
Yann Duran
@yannduran
is this in the experimental instance? or when the extension is installed?
bluetarpmedia
@bluetarpmedia
VS 2017 Experimental
Yann Duran
@yannduran
have you tried it when it's installed?
bluetarpmedia
@bluetarpmedia
No, not yet. The underlying setting persists across different runs of VS 2017 experimental. So it's correctly setting/reading the value. The problem is Tools->Options reads the value from the BaseOptionPage instance of the model
And the code that sets the value is setting it on a different instance of the model. Both models read/write to the same settings store, but the model data can be out-of-sync
Yann Duran
@yannduran
i'd check to see if it works as expected installed, it may just be an experimental instance thing
other than that i don't know what else to suggest, sorry
bluetarpmedia
@bluetarpmedia
thanks, will do.
btw @yannduran I saw you're based in Melbourne; I'm up in Bris
Yann Duran
@yannduran
cool
no wonder we're online at the same time
Ed
@pachif
Hi everyone
if I need some guidance on first step on a text editor with intelisense, which will be querying a database, and I also need the view of data
CyrusNajmabadi
@CyrusNajmabadi
how many years do you have at your disposal?
Matt Lacey
@mrlacey
Ed
@pachif
@CyrusNajmabadi LOL! :)
thanks for the links for starters @mrlacey
Ed
@pachif
image.png
ok I think I will forget the intelisense for now, I try to do an UI similar to SQL Query VS plug in
Ramon Viladomat
@Viladoman
Hi everyone!
I hope someone here can help me. I added a IVsOutputWindowPane for my extension. When I trigger a command I want to display some output text. Sadly I can't find a way to get active focus to the output window and my pane so it becomes obvious to the user that something has been triggered. How can I have the same behavior as the Build output pane when a build is triggered?
Thanks!
Filip-226
@Filip-226
Hi everyone
Can I rename the default Debug/Compile button as 'Attach to XXX'?
reduckted
@reduckted
@Viladoman You should be able to use the IVsOutputWindowPage.Activate() method to make it the active output window.
Sergey M
@usysware
Having a problem with my IGlyphFactoryProvider getting invoked when opening WPF .xaml files. Everything works fine for plain text and Xml files though. Here's my IGlyphFactoryProvider implementation: https://github.com/usysware/dpack/blob/master/DPackRx/Features/Bookmarks/BookmarksGlyphFactoryProvider.cs
I'd appreciate any suggestions. Thanks.
Rastko Tojagic
@rtojagic
Hey guys, I am working on a C++ project extension, and I have source files in a separate directory from project files, I want my extension to be able to delete the source files
image.png
this is what I have so far, but this will only remove the file from the project and not the actual file on disk, is there any way I can access and remove file on disk from here?
qpooqp
@qpooqp
Hi guys.
I was recently thinking about creating some extensions (mainly for learning purposes), and i was wondering if it is possible to access/change built in tool windows. More exactly call stack / autos / locals.
I was trying to find out on my own, but with no luck.
Does anybody know?
Thank you.
Paul M Cohen
@paul1956
@qpooqp If you want your own tool window like the ones you listed search "Writing Visual Studio Extensions with Mads - Creating a tool window extension" there are 9 others with lots of information about creating extensions. The entire series starts at https://www.youtube.com/results?search_query=writing+visual+studio+extensions+with+mads+-+episode
qpooqp
@qpooqp
@paul1956 Yes, i know that you can write your own from scratch, but one think i wanted to try was to change a bit the appearance/functionality of the default ones (the ones i listed). I tried to find some ways, on internet, but i was not successful. I think that it is probably not possible, but wanted to confirm that with somebody who has some experience with that.
2 replies
Rastko Tojagic
@rtojagic
Hey, I got another issue, anyone knows why projectItem.Properties.Parent is the same as projectItem? I need to access the filter that contains the currently selected source file
colosso
@colosso
Hello everyone, could someone here tell me if there is any resource / documentation or examples about Microsoft.VisualStudio.Shell.Flavor? Or maby just some information about how FlavoredProjectFactory and FlavoredProjectBase can be used? Any help would be very appreciated!