FrameworkElement events not supported

Gavin Williams 761 Reputation points

I was trying to resolve an issue where 'multiple assemblies with the same identity have been imported" so I removed one of the assemblies (System.Runtime.InteropServices) but then i started getting this message ..

CS1545 Property, indexer, or event 'FrameworkElement.SizeChanged' is not supported by the language; try directly calling accessor methods 'FrameworkElement.add_SizeChanged(SizeChangedEventHandler)' or 'FrameworkElement.remove_SizeChanged(EventRegistrationToken)'

I added System.Runtime.InteropServices back in. But I haven't fixed it. Have I made a mistake and added the wrong nuget package back in?

Universal Windows Platform (UWP)
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Gavin Williams 761 Reputation points

    I think the package i needed to add was: System.Runtime.InteropServcies.WindowsRuntime