我想显示我的一个图标(.ico文件),它们位于.resx文件中。 This这种方式适用于图像,但我无法弄清楚如何使用图标。这样它就可以显示系统图标:
System::Drawing::Icon^ officialicon = gcnew System::Drawing::Icon(SystemIcons::Exclamation, 48,48);
IconPictureBox->Image = officialicon->ToBitmap();
但我不能让它像这样工作:
ResourceManager^ rm = gcnew ResourceManager("Control_Panel.Resource", GetType()->Assembly);
System::Drawing::Icon^ officialicon = gcnew System::Drawing::Icon(rm->GetObject(L"MyIcon"), 48,48);
IconPictureBox->Image = officialicon->ToBitmap();
我需要从System::Object
到System::Drawing::Icon
进行某种演员表吗?
答案 0 :(得分:0)
好的,我想通了,我需要把它投到<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
:
System::Drawing::Icon