File tree Expand file tree Collapse file tree 6 files changed +18
-32
lines changed
ValidateOnLoad/ValidateOnLoad Expand file tree Collapse file tree 6 files changed +18
-32
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,10 @@ public partial class App : Application
55 public App ( )
66 {
77 InitializeComponent ( ) ;
8-
9- MainPage = new AppShell ( ) ;
108 }
9+
10+ protected override Window CreateWindow ( IActivationState ? activationState )
11+ {
12+ return new Window ( new MainPage ( ) ) ;
13+ }
1114}
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 22<ContentPage xmlns =" http://schemas.microsoft.com/dotnet/2021/maui"
33 xmlns : x =" http://schemas.microsoft.com/winfx/2009/xaml"
44 xmlns : local =" clr-namespace:ValidateOnLoad"
5+ x : DataType =" local:DataFormViewModel"
56 xmlns : dataForm =" clr-namespace:Syncfusion.Maui.DataForm;assembly=Syncfusion.Maui.DataForm"
67 x : Class =" ValidateOnLoad.MainPage" >
78
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ namespace ValidateOnLoad
44{
55 public class DataFormBehavior : Behavior < ContentPage >
66 {
7- private SfDataForm dataForm ;
7+ private SfDataForm ? dataForm ;
88 protected override void OnAttachedTo ( ContentPage bindable )
99 {
1010 base . OnAttachedTo ( bindable ) ;
@@ -18,9 +18,9 @@ protected override void OnAttachedTo(ContentPage bindable)
1818 }
1919 }
2020
21- private void OnLoaded ( object sender , EventArgs e )
21+ private void OnLoaded ( object ? sender , EventArgs e )
2222 {
23- this . dataForm . Validate ( ) ;
23+ this . dataForm ? . Validate ( ) ;
2424 }
2525
2626 protected override void OnDetachingFrom ( ContentPage bindable )
Original file line number Diff line number Diff line change 11<Project Sdk =" Microsoft.NET.Sdk" >
22
33 <PropertyGroup >
4- <TargetFrameworks >net7 .0-android;net7 .0-ios;net7 .0-maccatalyst</TargetFrameworks >
5- <TargetFrameworks Condition =" $([MSBuild]::IsOSPlatform('windows'))" >$(TargetFrameworks);net7 .0-windows10.0.19041.0</TargetFrameworks >
4+ <TargetFrameworks >net9 .0-android;net9 .0-ios;net9 .0-maccatalyst</TargetFrameworks >
5+ <TargetFrameworks Condition =" $([MSBuild]::IsOSPlatform('windows'))" >$(TargetFrameworks);net9 .0-windows10.0.19041.0</TargetFrameworks >
66 <!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
77 <!-- <TargetFrameworks>$(TargetFrameworks);net7.0-tizen</TargetFrameworks> -->
88 <OutputType >Exe</OutputType >
99 <RootNamespace >ValidateOnLoad</RootNamespace >
1010 <UseMaui >true</UseMaui >
1111 <SingleProject >true</SingleProject >
1212 <ImplicitUsings >enable</ImplicitUsings >
13+ <Nullable >enable</Nullable >
1314
1415 <!-- Display name -->
1516 <ApplicationTitle >ValidateOnLoad</ApplicationTitle >
4950 </ItemGroup >
5051
5152 <ItemGroup >
52- <PackageReference Include =" Microsoft.Extensions.Logging.Debug" Version =" 7.0.0" />
53- <PackageReference Include =" Syncfusion.Maui.DataForm" Version =" *" />
53+ <PackageReference Include =" Microsoft.Extensions.Logging.Debug" Version =" *" />
54+ </ItemGroup >
55+
56+ <ItemGroup >
57+ <PackageReference Include =" Microsoft.Maui.Controls" Version =" $(MauiVersion)" />
58+ <PackageReference Include =" Syncfusion.Maui.DataForm" Version =" *" />
5459 </ItemGroup >
5560
5661</Project >
You can’t perform that action at this time.
0 commit comments