Click here to Skip to main content
15,905,616 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
Generaldrop-down text field Pin
Dan Broomall30-Jan-04 9:25
Dan Broomall30-Jan-04 9:25 
GeneralArithmeticException (overflow) in System.Drawing.Font Pin
A.Obraztsov29-Jan-04 23:33
A.Obraztsov29-Jan-04 23:33 
GeneralBinaryReader and BinaryWriter and "Endianess" Pin
Paul Selormey29-Jan-04 22:06
Paul Selormey29-Jan-04 22:06 
QuestionHow do I change the icon on the dialog? Pin
adonisv29-Jan-04 20:15
adonisv29-Jan-04 20:15 
AnswerRe: How do I change the icon on the dialog? Pin
Mike Ellison30-Jan-04 5:50
Mike Ellison30-Jan-04 5:50 
GeneralRe: How do I change the icon on the dialog? Pin
Dan Broomall30-Jan-04 9:30
Dan Broomall30-Jan-04 9:30 
GeneralRe: How do I change the icon on the dialog? Pin
adonisv5-Feb-04 9:19
adonisv5-Feb-04 9:19 
GeneralRe: How do I change the icon on the dialog? Pin
Dan Broomall5-Feb-04 9:45
Dan Broomall5-Feb-04 9:45 
Okay. I just ran a test of this and I have found two specific ways of doing this (although I am sure there are more out there). I created a project and added two different looking icons. The first I went into the form's properties and changed the icon there. The mis-leading part is that even though your icons are loaded as "part" of your project/solution, you will still have to reference them by path and filename. So, I set one of them at design time to make sure that worked. It did.

Once this was successful, I went into the Form1_Load procedure and created an object of type System.Drawing.Icon. This has 6 different constructors, one of which accepts a path/filename. I created that and passed it "..\Icon2.ico" as the path/filename (.. because the root for execution is bin and I had the file in the main project directory). I then simply set the Me.Icon property to the Icon object I had just created. All tests were successful.

Does this make sense?
GeneralPossible memory leak in System.Windows.Forms (Icon property) Pin
Palladino29-Jan-04 8:47
Palladino29-Jan-04 8:47 
QuestionHow to tell if I have SP1 or SP2 installed on th box? Pin
Anonymous29-Jan-04 8:35
Anonymous29-Jan-04 8:35 
GeneralGetting a custom components' parent Pin
2sky29-Jan-04 4:55
2sky29-Jan-04 4:55 
Questionhow to Include Dotnet Framework in my project msi Pin
payal sheth29-Jan-04 1:46
payal sheth29-Jan-04 1:46 
AnswerRe: how to Include Dotnet Framework in my project msi Pin
devvvy29-Jan-04 1:56
devvvy29-Jan-04 1:56 
GeneralRe: how to Include Dotnet Framework in my project msi Pin
devvvy29-Jan-04 1:57
devvvy29-Jan-04 1:57 
GeneralRe: how to Include Dotnet Framework in my project msi Pin
Anonymous1-Feb-04 21:12
Anonymous1-Feb-04 21:12 
GeneralRe: how to Include Dotnet Framework in my project msi Pin
Terrence J. Joubert1-Feb-04 23:51
Terrence J. Joubert1-Feb-04 23:51 
GeneralRe: how to Include Dotnet Framework in my project msi Pin
Norman Fung2-Feb-04 0:02
Norman Fung2-Feb-04 0:02 
AnswerRe: how to Include Dotnet Framework in my project msi Pin
godzooky2-Feb-04 4:53
godzooky2-Feb-04 4:53 
GeneralCOM extended - Excel Pin
Praveen Nayak28-Jan-04 17:42
Praveen Nayak28-Jan-04 17:42 
GeneralDrawImage blurs when resizing image Pin
Michael Menne28-Jan-04 10:18
Michael Menne28-Jan-04 10:18 
GeneralSetting HWND handle to a .NET Windows form Pin
MrBean27-Jan-04 22:04
MrBean27-Jan-04 22:04 
GeneralRe: Setting HWND handle to a .NET Windows form Pin
Serge Lobko-Lobanovsky27-Jan-04 22:35
Serge Lobko-Lobanovsky27-Jan-04 22:35 
GeneralRe: Setting HWND handle to a .NET Windows form Pin
MrBean27-Jan-04 22:39
MrBean27-Jan-04 22:39 
GeneralRe: Setting HWND handle to a .NET Windows form Pin
Serge Lobko-Lobanovsky27-Jan-04 23:10
Serge Lobko-Lobanovsky27-Jan-04 23:10 
GeneralRe: Setting HWND handle to a .NET Windows form Pin
MrBean27-Jan-04 23:45
MrBean27-Jan-04 23:45 

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.