Yes, the managed runtime is replacing your form's Icon.
Try something like this:
public partial class MyForm : Form
{
public MyForm()
{
InitializeComponent(); // designed icon is set here
myIcon = this.Icon; // save the designed icon
this.VisibleChanged += MyForm_VisibleChanged;
}
private Icon myIcon = null;
private void MyForm_VisibleChanged(object sender, EventArgs e)
{
if( myIcon != null )
this.Icon = myIcon;
this.VisibleChanged -= MyForm_VisibleChanged;
}
}
--
http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD 2008
Supporting AutoCAD 2000 through 2008
http://www.acadxtabs.com
wrote in message news:5625720@discussion.autodesk.com...
Hi,
I'd like to display my icon on my C# form. However it appears that the Autocad icon overides mine. Firstly, is that what is really happening, and secondly, how can I override it?
With thanks