I have a single window application, basically a calculator, where I can change individual entries on the fly to generate a new profit/break-even answer based on the new price/weight etc. just entered. Each entry view is bound to a stepper value for quick small adjustments or the entry can be edited for big changes. How do I save the value, that the stepper is currently on, for use the next time the application is used??
<Grid x:Name="PurchasePriceGrid">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width=".6*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="40" />
</Grid.RowDefinitions>
<Label Text="Purchase Price" TextColor="Black" FontAttributes="Bold" Margin="0,0,25,0" Scale="1.2" TranslationX="15"
Grid.Column="0" HorizontalTextAlignment="End" VerticalTextAlignment="Center" LineBreakMode="NoWrap" />
<customentry:MyEntry x:Name="PurchasePriceEntry" Text="{Binding Source={x:Reference PurchasePriceStepper}, Path=Value, FallbackValue=0}"
TextColor="DarkSlateGray" FontAttributes="Bold" BackgroundColor="Ivory" TranslationX="10"
Grid.Column="1" HorizontalTextAlignment="Center" Keyboard="Numeric" VerticalOptions="End" MaxLength="5"
TextChanged="PurchasePriceEntry_Completed" />
<Stepper x:Name="PurchasePriceStepper" Grid.Column="2" HorizontalOptions="Center" VerticalOptions="Center" Scale=".7" TranslationX="3"
Maximum="5" Minimum=".01" Increment=".01" Value="1.75" />
</Grid>
I don't want to have to go through each entry and change the values to get back to where I left off every time I open the application, as it does now... I am new to programming and I can't find any example of this for me to follow. I'm guessing I need to somehow use something like INotifyPropertyChanged like here Xamarin Forms - update a label value and if so how do I do that with a stepper value? Or is there a better way to get my desired result???