Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

WPF .NET Core 3.0 Settings

$
0
0

The following code from WPF application in .NET 4.8 works just fine, 

<Window x:Class="Vtsr.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:Vtsr"
        xmlns:p="clr-namespace:Vtsr.Properties"
        mc:Ignorable="d"
        Left="{Binding Source={x:Static p:Settings.Default},
                                            Path=VisitWindowLeft,
                                            Mode=TwoWay}"
        Title="MainWindow" Height="450" Width="800"

>

but in .NET Core 3.0 I am getting 

ErrorXDG0062Could not load file or assembly 'Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.VtsrMainWindow.xaml

The offending line is  Left="{Binding Source={x:Static p:Settings.Default},
                                            Path=VisitWindowLeft,
                                            Mode=TwoWay}"

What am I doing wrong?


Peter


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>