Couchbase.Lite.Support.NetDesktop.Activate() vs Windows 10 iot enterprise 2016 ltsb

Hi,

I’m writing to you cause in our project after reworking from couchbase lite 1.4 to 2.1 we found a problem that the database cannot be created on Windows 10 iot enterprise 2016 ltsb. On machines with windows 10 premium / enterprise 64/32 bits there is no problem with that, however on the one I mentioned we cannot make it working, so I’m looking for an advice.

Before creating database with configuration we’re calling:

Couchbase.Lite.Support.NetDesktop.Activate();

We got following exception:

System.TypeInitializationException: The type initializer for 'Couchbase.Lite.Interop.Native' threw an exception. ---> System.InvalidOperationException: A required dependency injection class is missing (LiteCore.Interop.ILiteCore).
                  Please ensure that you have called the proper Activate() class in the
                  support assembly (e.g. Couchbase.Lite.Support.UWP.Activate()) or that you
                  have manually registered dependencies via the Couchbase.Lite.DI.Service
                  class.
at Couchbase.Lite.DI.Service.GetRequiredInstance[T]()
at Couchbase.Lite.Interop.Native..cctor()
--- End of inner exception stack trace ---
at Couchbase.Lite.Interop.Native.c4query_free(C4Query* x)
at Couchbase.Lite.Internal.Query.XQuery.Dispose(Boolean finalizing)
at Couchbase.Lite.Internal.Query.XQuery.Finalize()

We’re calling that Activate() method inside class library,
Target framework: .NET Framework 4.6.1.

How can we make it work on Windows 10 iot enterprise 2016 ltsb ?

Thanks in Advance.

Kind Regards,
Piotr

Is that an ARM board? If so we don’t have an ARM build for regular .NET (only UWP).

Well, it’s not ARM. We’re talking about that device:

Build version of the system: 10.0.14393.

What’s interesting on a virtual machine with the system with exactly the same version, everything is working as expected.

Any ideas?

Piotr

That sounds like possibly one has the Microsoft visual c++ 2015 redistributable (or visual studio 2015 itself) installed and the other does not.

@borrrden - Thank you very much for lightning fast help. Yes indeed lack of Microsoft visual c++ 2015 redistributable was a problem.

You can mark as resolved.

Thank you!

Piotr