【发布时间】:2013-03-08 07:22:10
【问题描述】:
我收到以下错误:
An unhandled exception of type 'System.StackOverflowException'
occurred in ciscontrols.dll
以下是相关代码:
private int Dval;
public int DecPlaces
{
get { return Dval; }
set
{
DecPlaces = value;
if (value < 2)
{
throw new ArgumentOutOfRangeException("decplaces", "decimal places minimum value should be 2.");
}
else this.Dval = value;
}
}
【问题讨论】:
-
DecPlaces = value应该做什么?
标签: c# winforms user-controls get set