.net cf 1 Extract Icon

  • Thread starter Thread starter Thorsten Held
  • Start date Start date
This is assuming the icon is in the current executing assembly and you're
dealing with managed code only:

Stream stream =
Assembly.GetExecutingAssembly().GetManifestResourceStream("namespacetoicon.myicon.ico");
Icon icon = new Icon(stream);

If the exe in not in the callers context (and is managed) use the
Assembly.LoadFrom method.

I think Alex's post is loading an icon from any executable (native or
managed).
 
Back
Top