【发布时间】:2016-10-07 22:37:59
【问题描述】:
我已添加 System.Drawing 作为参考,但此代码似乎在我声明新颜色的那一行失败
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Drawing;
using System.Windows.Forms;
using System.IO;
namespace BitmapParser
{
class Program
{
static void Main(string[] args)
{
Color a = Color.FromARgb(0, 255, 0);
}
}
}
那么这里发生了什么?我查找了 System.Drawing.Color 并且它确实有一个 3-int 构造函数 https://msdn.microsoft.com/en-us/library/system.drawing.color.aspx
【问题讨论】:
-
c# 区分大小写。小写“r”
-
我有以下两条非常有用的信息给您: 1. FromArgb() 不是 构造函数。 2. 计算机在大小写方面往往非常挑剔。
标签: c# system.drawing system.drawing.color