question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

LottieSharp.WPF.LottieAnimationView threw an exception in Version 2.0.1

See original GitHub issue

Hello. After installing the LottieSharp(V 2.0.1), and adding the namespace in the xaml file and the corresponding tag, it gives the following message ===================== MY Code ===================== NameSpace: xmlns:lottie=“clr-namespace:LottieSharp.WPF;assembly=LottieSharp”

  <lottie:LottieAnimationView
                                Width="200"
                                Height="300"
                                HorizontalAlignment="Center"
                                VerticalAlignment="Center"
                                AutoPlay="True"
                                FileName="C:\Res\Images\Public\data_not_found.json" 
                                RepeatCount="-1" />

Exeption Error:

System.Windows.Markup.XamlParseException: ‘The type initializer for ‘LottieSharp.WPF.LottieAnimationView’ threw an exception.’

     ------  ↓ and ↓ -------

FileNotFoundException: Could not load file or assembly 'WindowsBase, Version=6.0.2.0, Culture=neutral, 
     PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified.

*** One thing I have to say is that the json file is available in the specified path.

Has anyone had this problem? ===================== MY Code ===================== 1

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
buaishicommented, Oct 12, 2022

I had the same problem

0reactions
quicolicommented, Apr 11, 2023

See release 2.2.0

Read more comments on GitHub >

github_iconTop Results From Across the Web

quicoli/LottieSharp: Lottie animations for WPF applications
Version 2.0.1. Fixed issue #57. Fixed issue with animation details not being displayed in databinding. Properties, Methods and Events ...
Read more >
Unable to catch exception due to parsing errors in json #999
I need to ensure in that case the app doesn't crashes or library throws appropriate exception that can be caught.
Read more >
Lottie animation slows down my other native wpf animations
I am using them in button, so my solution for now is, when the button appears, to load it: animation = new LottieAnimationView();...
Read more >
Using Lottie images in WPF .Net5 - Microsoft Q&A
My project is WPF and target framework is .NET 5.0. I want to use Lottie images. I wanted to use Lottie without converting...
Read more >
Exception when a WPF window is displayed
When WPF detects this, it is considered a fatal condition and WPF purposely calls System.Environment.FailFast , which throws a System.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found