WdColor的值和int是可以相互转换的 所以你只要把Color的值转成int 然后赋给它就行了 代码如下using Microsoft.Office.Interop.Word; private void button1_Click(object sender, EventArgs e)
{
Color blue = ColorTranslator.FromWin32((int)WdColor.wdColorBlue);//系统WdColor转Color
WdColor wdBlue = (WdColor)ColorTranslator.ToWin32(Color.Blue);//系统Color转WdColor
WdColor wdCustom = (WdColor)ColorTranslator.ToWin32(Color.FromArgb(12, 34, 56));//自定义Color转WdColor
Color custom = ColorTranslator.FromWin32((int)wdCustom);//自定义WdColor转Color
}
温馨提示:答案为网友推荐,仅供参考