Attempting to use GMaps gives an SQLite.Interop.dll error

0

I am trying to add Gmaps to my dotnet framework application. I am following this tutorial, and yet I always get the following error:

Unable to load DLL 'SQLite.Interop.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

My code is as follows:

MapControl.cs

using GMap.NET.WindowsPresentation;

namespace MapsPoC
{
    class MapControl: GMapControl
    {
    }
}

MainWindow.xaml

<Window x:Class="MapsPoC.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:MapsPoC"
        mc:Ignorable="d"
        Title="MainWindow" Height="450" Width="800">
    <Grid>
        <GroupBox Name="mapgroup" VerticalContentAlignment="Stretch" HorizontalContentAlignment="Stretch">
            <local:MapControl x:Name="mapControl" Zoom="13" MaxZoom="24" MinZoom="1" />
        </GroupBox>
    </Grid>
</Window>

packages.config

<?xml version="1.0" encoding="utf-8"?>
<packages>
  <package id="EntityFramework" version="6.3.0" targetFramework="net472" />
  <package id="GMap.NET.Core" version="2.0.1" targetFramework="net472" />
  <package id="GMap.NET.Windows" version="2.0.1" targetFramework="net472" />
  <package id="GMap.NET.WinForms" version="2.0.1" targetFramework="net472" />
  <package id="GMap.NET.WinPresentation" version="2.0.1" targetFramework="net472" />
  <package id="Newtonsoft.Json" version="12.0.3" targetFramework="net472" />
  <package id="Stub.System.Data.SQLite.Core.NetFramework" version="1.0.113.3" targetFramework="net472" />
  <package id="System.Data.SQLite" version="1.0.113.7" targetFramework="net472" />
  <package id="System.Data.SQLite.Core" version="1.0.113.7" targetFramework="net472" />
  <package id="System.Data.SQLite.EF6" version="1.0.113.0" targetFramework="net472" />
  <package id="System.Data.SQLite.Linq" version="1.0.113.0" targetFramework="net472" />
</packages>

Error: error image Can anyone help me please? What am I missing?

To add to the confusion, the app still builds and runs (at least in debug mode) and yet I still see the error

asp.net
gmap.net
asked on Stack Overflow Jan 13, 2021 by PMO1948 • edited Jan 13, 2021 by PMO1948

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0