当前位置:编程学习 > C#/ASP.NET >>

c# decimal.operator ++(decimal)”: 无法显式调用运算符或访问

  public decimal Lenth
        {
            get
            {
                return decimal.op_Increment(this.Percentage * Convert.ToDecimal((double)4.2));//这里提示
            }
        }

        private void op_Increment(decimal p)
        {
            throw new NotImplementedException();
        }

        private object Increment(decimal p)
        {
            throw new NotImplementedException();
        } C# --------------------编程问答-------------------- Percentages是什么类型? 
既然 Convert.ToDecimal了 里面就不需要再double
(Convert.ToDecimal(this.Percentages) * Convert.ToDecimal(4.2)) --------------------编程问答--------------------

        
--------------------编程问答--------------------

            什么原因啊,
    return decimal.op_Increment(this.Percentage * Convert.ToDecimal((double)4.2));//这里提示
补充:.NET技术 ,  C#
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,