Click here to Skip to main content
15,891,951 members
Home / Discussions / C#
   

C#

 
AnswerRe: Excel Addins deploy problem Pin
wasimsharp10-Aug-08 22:16
wasimsharp10-Aug-08 22:16 
GeneralRe: Excel Addins deploy problem Pin
Mogaambo10-Aug-08 23:06
Mogaambo10-Aug-08 23:06 
Questionwmi Pin
arkiboys10-Aug-08 21:17
arkiboys10-Aug-08 21:17 
AnswerRe: wmi Pin
half-life10-Aug-08 23:16
half-life10-Aug-08 23:16 
AnswerRe: wmi Pin
Mark Salsbery11-Aug-08 6:50
Mark Salsbery11-Aug-08 6:50 
QuestionIcon Pin
Silvyster10-Aug-08 21:16
Silvyster10-Aug-08 21:16 
AnswerRe: Icon Pin
Thomas Stockwell11-Aug-08 1:28
professionalThomas Stockwell11-Aug-08 1:28 
AnswerRe: Icon Pin
DaveyM6911-Aug-08 3:38
professionalDaveyM6911-Aug-08 3:38 
This works - it's code I found on the internet in VB which I've converted to C#. It's a bit messy so could probably be tidied up a bit but it's a starter.
C#
Bitmap myBitmap = new Bitmap(@"c:\pic.jpg");
Bitmap bmp = new Bitmap(32, 32);
Graphics g = Graphics.FromImage(bmp);
g.DrawImage(myBitmap, 0, 0, 32, 32);
IntPtr HIcon = bmp.GetHicon();
Icon newIcon = System.Drawing.Icon.FromHandle(HIcon);
FileStream stream = new FileStream(@"c:\pic.ico", FileMode.Create);
newIcon.Save(stream);
stream.Dispose();
g.Dispose();


Dave
BTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)
Expect everything to be hard and then enjoy the things that come easy. (code-frog)

Question[Message Deleted] Pin
Charith Jayasundara10-Aug-08 20:54
Charith Jayasundara10-Aug-08 20:54 
AnswerRe: Integrate World Map to .net site Pin
Christian Graus10-Aug-08 20:57
protectorChristian Graus10-Aug-08 20:57 
QuestionHttp header fields Pin
George_George10-Aug-08 20:53
George_George10-Aug-08 20:53 
AnswerRe: Http header fields Pin
Mark Salsbery10-Aug-08 21:03
Mark Salsbery10-Aug-08 21:03 
GeneralRe: Http header fields Pin
George_George10-Aug-08 21:17
George_George10-Aug-08 21:17 
GeneralRe: Http header fields Pin
Mark Salsbery10-Aug-08 21:30
Mark Salsbery10-Aug-08 21:30 
GeneralRe: Http header fields Pin
George_George10-Aug-08 21:43
George_George10-Aug-08 21:43 
GeneralRe: Http header fields Pin
Mark Salsbery11-Aug-08 5:30
Mark Salsbery11-Aug-08 5:30 
GeneralRe: Http header fields Pin
George_George11-Aug-08 19:53
George_George11-Aug-08 19:53 
GeneralRe: Http header fields Pin
Mark Salsbery12-Aug-08 4:23
Mark Salsbery12-Aug-08 4:23 
GeneralRe: Http header fields Pin
George_George12-Aug-08 16:15
George_George12-Aug-08 16:15 
QuestionCertificate verification using CRL Pin
Ajil George10-Aug-08 20:50
Ajil George10-Aug-08 20:50 
AnswerRe: Certificate verification using CRL Pin
Peter Ritchie17-Aug-08 19:32
Peter Ritchie17-Aug-08 19:32 
Questiondata base deployment along with setup file Pin
vishnukamath10-Aug-08 20:46
vishnukamath10-Aug-08 20:46 
AnswerRe: data base deployment along with setup file Pin
Christian Graus10-Aug-08 20:59
protectorChristian Graus10-Aug-08 20:59 
Generalscrollbar with pan zoom Pin
smsurendar10-Aug-08 20:29
smsurendar10-Aug-08 20:29 
GeneralRe: scrollbar with pan zoom Pin
Paul Conrad10-Aug-08 20:53
professionalPaul Conrad10-Aug-08 20:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.