- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
In Revit 2020, I can create a new C# module, create a new C# Macro, go to Project, Add New Item, and add a WPF C# Window which is named Window1.
If I then select the Window1 I can view the code. Clicking the "Design" tab at the bottom of the code window shows a preview of the window.
In Revit 2021, I get no preview. Just an error message:
System.NullReferenceException: Object reference not set to an instance of an object.
at ICSharpCode.FormsDesigner.Services.TypeResolutionService..ctor()
at ICSharpCode.WpfDesign.AddIn.MyTypeFinder..ctor()
at ICSharpCode.WpfDesign.AddIn.MyTypeFinder.Create(OpenedFile file)
at ICSharpCode.WpfDesign.AddIn.WpfViewContent.LoadInternal(OpenedFile file, Stream stream)
at ICSharpCode.SharpDevelop.Gui.AbstractViewContentHandlingLoadErrors.Load(OpenedFile file, Stream stream)
Is there any fix?
Solved! Go to Solution.