FloatingPointControl 1.0.3

Additional Details

When the value of `MaxAllowedDecimalPlaces` is set to zero, the control still receives decimal values.

There is a newer version of this package available.
See the version list below for details.
The owner has unlisted this package. This could mean that the package is deprecated, has security vulnerabilities or shouldn't be used anymore.
dotnet add package FloatingPointControl --version 1.0.3
                    
NuGet\Install-Package FloatingPointControl -Version 1.0.3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="FloatingPointControl" Version="1.0.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="FloatingPointControl" Version="1.0.3" />
                    
Directory.Packages.props
<PackageReference Include="FloatingPointControl" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add FloatingPointControl --version 1.0.3
                    
#r "nuget: FloatingPointControl, 1.0.3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package FloatingPointControl@1.0.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=FloatingPointControl&version=1.0.3
                    
Install as a Cake Addin
#tool nuget:?package=FloatingPointControl&version=1.0.3
                    
Install as a Cake Tool

Floating Poin Controls for WPF

NuGet Package

NuGet Package Version medium Story

There is no built-in control for floating-point inputs in Windows Presentation Foundation (WPF). Using TextBox for managing floating-point inputs can be a challange for a developer. If all you need is a floating-point input with seamless WPF compatibility, this package is for you.

There is only a DoubleInput control currently.

Features:

  • Accepts only digits, negative sign (-) at the beginning and decimal seperator of the culture information only once.
  • Does not response and change the text if any char is entered other than the accepted ones.
  • Fires event when value is changed,
  • Value changes only when the text is parsable as a floating-point number.
  • suitible to be used with data binding even with TwoWay binding mode.
  • Style properties such as, text size, text weight, alignment shall be accessible for customizable visual styling.
  • Maximum number of decimal places can bes set by XAML file.
  • Can be set to trim trailing zeros after last meaningful deciaml digit or decimal seperator.
  • Whole text is selected when the control is double-clicked.

Example:

WPF Sample With Circular Dependent Inputs

<Window ... 
    xmlns:controls="clr-namespace:FloatingPointControls;assembly=FloatingPointControl" 
... />
<controls:DoubleInput 
            Grid.Column="1" 
            Value="{Binding T,  Mode=TwoWay}"
            Style="{StaticResource DoubleInputStyle}"
            MaxAllowedDecimalPlaces ="3"/>

How-To

Making Integer Control

To make the control only accept integer values set MaxAllowedDecimalPlaces property to 0.

Product Compatible and additional computed target framework versions.
.NET net6.0-windows7.0 is compatible.  net7.0-windows was computed.  net8.0-windows was computed.  net9.0-windows was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net6.0-windows7.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.7 194 10/14/2025
1.0.6 255 8/8/2025
1.0.5 423 7/25/2025
1.0.4 374 7/20/2025
1.0.2 244 2/9/2024
1.0.1 171 1/23/2024

- MaxAllowedDecimalPlaces property is binded with dependency property.
- Readme is updated