changing application icon at runtime without recompiling
-
Hi there, I hope that every .net programmer knows about app.ico. If not then create a windows application in c# and check out the working folder. You could see such a file there. This file is the picture file that is displayed in the exe file(check out debug folder of your application). Now what i need is, i want to change this app.ico through c# coding. Is it possible for changing the application icon at runtime without re-compiling? When i mention a .ico file, at runtime, this new .ico file should replace the existing default app.ico file and my .exe file in debug folder should also posses this image. How can this be made?
-
Hi there, I hope that every .net programmer knows about app.ico. If not then create a windows application in c# and check out the working folder. You could see such a file there. This file is the picture file that is displayed in the exe file(check out debug folder of your application). Now what i need is, i want to change this app.ico through c# coding. Is it possible for changing the application icon at runtime without re-compiling? When i mention a .ico file, at runtime, this new .ico file should replace the existing default app.ico file and my .exe file in debug folder should also posses this image. How can this be made?
ok this is the fact, first you can do that for a very simple way, for instance: System .Drawing .Icon nuevo=new Icon (@"D:\MyIconDirection.ico"); Random manual=new Random (); int p = manual.Next (2); if (p == 1) base.Icon=nuevo; else base.Icon=null; and I dont know, you can use for repeat that many times, a timer, thread, delegate to do that ashyncrons:-D, you choose... for any question or another think write me... :-D:-D:-D