Closed giancarlomelis closed 3 years ago
One other user reported this issue, and it appears to be a problem between the designer and some other extension that you may have installed. Could you please post a copy of your Visual Studio log file? That may give a clue as to what's happening.
Thank you. Which log would you like specifically?
I'm after the IDE's log (https://docs.microsoft.com/en-us/visualstudio/ide/reference/log-devenv-exe?view=vs-2019). If you haven't ever created one of those, it can be quite long. 🤕
Hi. I've attached a log
maybe is this the point?
`
<time>2021/05/31 15:39:25.515</time>
<type>Error</type>
<source>VisualStudio</source>
<description>LegacySitePackage failed for package [EFModelPackage]Source: 'System.ComponentModel.Composition' Description: The composition produced a single composition error. The root cause is provided below. Review the CompositionException.Errors property for more detailed information.

1) No exports were found that match the constraint: 
	ContractName	Microsoft.VisualStudio.Modeling.ExtensionEnablement.IExtensibilityLogger
	RequiredTypeIdentity	Microsoft.VisualStudio.Modeling.ExtensionEnablement.IExtensibilityLogger

Resulting in: Cannot set import 'Microsoft.VisualStudio.Modeling.Shell.ExtensionEnablement.CommandExtensionRegistrar.mefImportedLogger (ContractName="Microsoft.VisualStudio.Modeling.ExtensionEnablement.IExtensibilityLogger")' on part 'Sawczyn.EFDesigner.EFModel.ExtensionEnablement.EFModelCommandExtensionRegistrar'.
Element: Microsoft.VisualStudio.Modeling.Shell.ExtensionEnablement.CommandExtensionRegistrar.mefImportedLogger (ContractName="Microsoft.VisualStudio.Modeling.ExtensionEnablement.IExtensibilityLogger") --> Sawczyn.EFDesigner.EFModel.ExtensionEnablement.EFModelCommandExtensionRegistrar

</description>
<guid>{56BBE1BA-AAEE-4883-848F-E3C8656F8DB2}</guid>
<hr>80131500</hr>
<errorinfo></errorinfo>
`
Thanks for providing that; it gave a lot of good information.
It appears the error is stemming from the MEF (meta-extensibility framework) subsystem in Visual Studio. I did some searching for those kinds of errors and they appear sporadically in reports for various MEF-enabled extensions, even for shipping parts of Visual Studio that are MEF-based (note that the designer contains MEF hooks in it).
There are a number of different solutions that have been given, from repairing Visual Studio and rebooting, to waiting for an update. It appears to be very hit-and-miss as to what fixes it at any given time, which tells me there are different root causes for the same behavior.
I'd suggest starting with clearing the MEF component cache. Mads has an extension that can help with that, or you can do it manually (info on that is on the Marketplace page linked above. If that doesn't work, you may have to do a repair, but that's a fairly long process so I wouldn't go there first.
Hello. Thanks for the reply. Unfortunately neither solution worked. Even after Visual Studio restore the model is not shown. Unfortunately I think I will have to give up.
Understandable. Thanks for trying, and I'm sorry I couldn't have been more help.
Hello! After creating the .efmodel file and open it, Visual Studio shows the xml content, but not the designer:
Microsoft Visual Studio Community 2019 Version 16.10.0
What can I do?