71 writes to Value
System.Windows.Forms (10)
System\Windows\Forms\Controls\UpDown\NumericUpDown.cs (8)
184
Value
= Constrain(_currentValue);
211
Value
= Constrain(_currentValue);
403
Value
= newValue;
412
Value
= Constrain(_currentValue);
537
Value
= Constrain(Convert.ToDecimal(Convert.ToInt32(Text, 16)));
541
Value
= Constrain(decimal.Parse(Text, CultureInfo.CurrentCulture));
595
Value
= DefaultValue;
692
Value
= newValue;
System\Windows\Forms\Printing\PrintPreviewDialog.cs (2)
1066
_pageCounter.
Value
= _previewControl.StartPage + 1;
1195
_pageCounter.
Value
= _previewControl.StartPage + 1;
System.Windows.Forms.Design (23)
System\Windows\Forms\Design\FormatControl.cs (1)
232
decimalPlacesUpDown.
Value
= 2;
System\Windows\Forms\Design\FormatControl.CurrencyFormatType.cs (7)
78
_owner.decimalPlacesUpDown.
Value
= 0;
82
_owner.decimalPlacesUpDown.
Value
= 1;
86
_owner.decimalPlacesUpDown.
Value
= 2;
90
_owner.decimalPlacesUpDown.
Value
= 3;
94
_owner.decimalPlacesUpDown.
Value
= 4;
98
_owner.decimalPlacesUpDown.
Value
= 5;
102
_owner.decimalPlacesUpDown.
Value
= 6;
System\Windows\Forms\Design\FormatControl.Designer.cs (1)
141
decimalPlacesUpDown.
Value
= new decimal(new int[] {
System\Windows\Forms\Design\FormatControl.NumericFormatType.cs (7)
77
_owner.decimalPlacesUpDown.
Value
= 0;
81
_owner.decimalPlacesUpDown.
Value
= 1;
85
_owner.decimalPlacesUpDown.
Value
= 2;
89
_owner.decimalPlacesUpDown.
Value
= 3;
93
_owner.decimalPlacesUpDown.
Value
= 4;
97
_owner.decimalPlacesUpDown.
Value
= 5;
101
_owner.decimalPlacesUpDown.
Value
= 6;
System\Windows\Forms\Design\FormatControl.ScientificFormatType.cs (7)
78
_owner.decimalPlacesUpDown.
Value
= 0;
82
_owner.decimalPlacesUpDown.
Value
= 1;
86
_owner.decimalPlacesUpDown.
Value
= 2;
90
_owner.decimalPlacesUpDown.
Value
= 3;
94
_owner.decimalPlacesUpDown.
Value
= 4;
98
_owner.decimalPlacesUpDown.
Value
= 5;
102
_owner.decimalPlacesUpDown.
Value
= 6;
System.Windows.Forms.Tests (24)
NumericUpDownTests.cs (22)
522
subUpDown.
Value
= 10;
533
subUpDown.
Value
= 10;
543
subUpDown.
Value
= 10;
565
upDown.
Value
= 50;
629
subUpDown.
Value
= 10;
634
subUpDown.
Value
= 20;
650
using NumericUpDown upDown = new() {
Value
= 0, Minimum = 0, Increment = 1 };
658
using NumericUpDown upDown = new() {
Value
= 10, Increment = 1, Text = "Not a number" };
666
using NumericUpDown upDown = new() {
Value
= 10, Minimum = 0, Maximum = 20, Increment = 1, Text = "30" };
677
Value
= 10
691
Value
= 15,
706
Value
= 11
720
Value
= 11,
743
using NumericUpDown upDown = new() {
Value
= 100, Maximum = 100, Increment = 1 };
751
using NumericUpDown upDown = new() {
Value
= 10, Increment = 1, Text = "Not a number" };
759
using NumericUpDown upDown = new() {
Value
= 10, Minimum = 0, Maximum = 20, Increment = 1, Text = "30" };
767
using NumericUpDown upDown = new() {
Value
= 100, Maximum = 100 };
775
using NumericUpDown upDown = new() {
Value
= 99, Maximum = 100 };
783
using NumericUpDown upDown = new() {
Value
= 100, Maximum = 100 };
791
using SubNumericUpDown upDown = new() {
Value
= 100, Maximum = 100, PublicUserEdit = true };
801
upDown.
Value
= decimal.MaxValue;
811
upDown.
Value
= decimal.MaxValue - 1;
System\Windows\Forms\AccessibleObjects\DirectionButtonAccessibleObjectTests.cs (2)
56
numericUpDown.
Value
= testValue;
73
numericUpDown.
Value
= testValue;
WinFormsControlsTest (14)
ComboBoxesWithScrollBars.cs (6)
26
changeDDH_UpDown1.
Value
= comboBox1.DropDownHeight;
27
changeCBHeight_UpDown2.
Value
= comboBox2.Size.Height;
28
changeDDH_UpDown3.
Value
= comboBox3.DropDownHeight;
31
maxDropDownItemsUpDown1.
Value
= comboBox1.MaxDropDownItems;
32
maxDropDownItemsUpDown2.
Value
= comboBox2.MaxDropDownItems;
33
maxDropDownItemsUpDown3.
Value
= comboBox3.MaxDropDownItems;
DataGridViewTest.Designer.cs (1)
175
this.numericUpDown1.
Value
= new decimal(new int[] {
ScrollBars.Designer.cs (1)
79
this.numericMaximum.
Value
= new decimal(new int[] {
TrackBars.cs (3)
15
numericMinimum.
Value
= trackBar1.Minimum;
16
numericMaximum.
Value
= trackBar1.Maximum;
17
numericFrequency.
Value
= trackBar1.TickFrequency;
TrackBars.Designer.cs (3)
155
this.numericMinimum.
Value
= new decimal(new int[] {
174
this.numericMaximum.
Value
= new decimal(new int[] {
193
this.numericFrequency.
Value
= new decimal(new int[] {
48 references to Value
System.Windows.Forms (7)
System\Windows\Forms\Controls\UpDown\NumericUpDown.cs (6)
13
[DefaultProperty(nameof(
Value
))]
15
[DefaultBindingProperty(nameof(
Value
))]
316
throw new ArgumentOutOfRangeException(nameof(value), value, string.Format(SR.InvalidBoundArgument, nameof(
Value
), value, $"'{nameof(Minimum)}'", $"'{nameof(Maximum)}'"));
331
/// Occurs when the <see cref="
Value
"/> property has been changed in some way.
624
/// Indicates whether the <see cref="
Value
"/> property should be persisted.
628
return !
Value
.Equals(DefaultValue);
System\Windows\Forms\Printing\PrintPreviewDialog.cs (1)
1184
int pageNum = ((int)_pageCounter.
Value
) - 1;
System.Windows.Forms.Design (3)
System\Windows\Forms\Design\FormatControl.CurrencyFormatType.cs (1)
35
switch ((int)_owner.decimalPlacesUpDown.
Value
)
System\Windows\Forms\Design\FormatControl.NumericFormatType.cs (1)
35
switch ((int)_owner.decimalPlacesUpDown.
Value
)
System\Windows\Forms\Design\FormatControl.ScientificFormatType.cs (1)
35
switch ((int)_owner.decimalPlacesUpDown.
Value
)
System.Windows.Forms.Tests (18)
NumericUpDownTests.cs (16)
552
upDown.
Value
.Should().Be(0);
566
upDown.
Value
.Should().Be(50);
652
upDown.
Value
.Should().Be(0);
660
upDown.
Value
.Should().Be(9);
668
upDown.
Value
.Should().Be(19);
682
upDown.
Value
.Should().Be(10);
697
subUpDown.
Value
.Should().Be(subUpDown.Minimum);
711
upDown.
Value
.Should().Be(10);
745
upDown.
Value
.Should().Be(100);
753
upDown.
Value
.Should().Be(11);
761
upDown.
Value
.Should().Be(20);
769
upDown.
Value
.Should().Be(100);
777
upDown.
Value
.Should().Be(100);
785
upDown.
Value
.Should().Be(100);
803
upDown.
Value
.Should().Be(decimal.MaxValue);
814
upDown.
Value
.Should().Be(decimal.MaxValue);
System\Windows\Forms\AccessibleObjects\DirectionButtonAccessibleObjectTests.cs (2)
63
Assert.Equal(testValue, numericUpDown.
Value
);
80
Assert.Equal(expected, numericUpDown.
Value
);
WinFormsControlsTest (20)
ComboBoxesWithScrollBars.cs (6)
51
comboBox1.DropDownHeight = (int)changeDDH_UpDown1.
Value
;
54
changeCBHeight_UpDown2.ValueChanged += (s, e) => comboBox2.Size = new Size(comboBox2.Size.Width, (int)changeCBHeight_UpDown2.
Value
);
57
comboBox3.DropDownHeight = (int)changeDDH_UpDown3.
Value
;
60
maxDropDownItemsUpDown1.ValueChanged += (s, e) => comboBox1.MaxDropDownItems = (int)maxDropDownItemsUpDown1.
Value
;
61
maxDropDownItemsUpDown2.ValueChanged += (s, e) => comboBox2.MaxDropDownItems = (int)maxDropDownItemsUpDown2.
Value
;
62
maxDropDownItemsUpDown3.ValueChanged += (s, e) => comboBox3.MaxDropDownItems = (int)maxDropDownItemsUpDown3.
Value
;
DataGridViewTest.cs (1)
93
Font = new Font("Tahoma", (float)numericUpDown1.
Value
, FontStyle.Regular);
ScrollBars.cs (6)
17
hScrollBar.Maximum = decimal.ToInt32(numericMaximum.
Value
);
18
vScrollBar.Maximum = decimal.ToInt32(numericMaximum.
Value
);
19
numericMinimum.Maximum = numericMaximum.
Value
;
25
hScrollBar.Minimum = decimal.ToInt32(numericMinimum.
Value
);
26
vScrollBar.Minimum = decimal.ToInt32(numericMinimum.
Value
);
27
numericMaximum.Minimum = numericMinimum.
Value
;
TrackBars.cs (7)
73
trackBar1.Minimum = (int)Math.Max(numericMinimum.
Value
, int.MinValue);
74
numericMaximum.Minimum = numericMinimum.
Value
;
75
numericFrequency.Maximum = (int)Math.Min(numericMaximum.
Value
- numericMaximum.Minimum, int.MaxValue);
86
trackBar1.Maximum = (int)Math.Min(numericMaximum.
Value
, int.MaxValue);
87
numericMinimum.Maximum = numericMaximum.
Value
;
88
numericFrequency.Maximum = (int)Math.Min(numericMaximum.
Value
- numericMaximum.Minimum, int.MaxValue);
99
trackBar1.TickFrequency = (int)numericFrequency.
Value
;