Click here to Skip to main content
15,922,894 members
Home / Discussions / C#
   

C#

 
GeneralRe: On calling a function written in c from a dotnet c# application Pin
Christian Graus20-Apr-08 19:54
protectorChristian Graus20-Apr-08 19:54 
GeneralRe: On calling a function written in c from a dotnet c# application Pin
Member 475670920-Apr-08 20:54
Member 475670920-Apr-08 20:54 
GeneralUser permissions to a DCOM object Pin
random420-Apr-08 19:15
random420-Apr-08 19:15 
GeneralRe: User permissions to a DCOM object Pin
Nouman Bhatti20-Apr-08 19:58
Nouman Bhatti20-Apr-08 19:58 
GeneralRe: User permissions to a DCOM object Pin
random421-Apr-08 18:33
random421-Apr-08 18:33 
GeneralLogin Winform Pin
ferspr20-Apr-08 17:34
ferspr20-Apr-08 17:34 
GeneralRe: Login Winform Pin
I.explore.code20-Apr-08 18:44
I.explore.code20-Apr-08 18:44 
GeneralRe: Login Winform Pin
ferspr20-Apr-08 19:27
ferspr20-Apr-08 19:27 
GeneralRe: Login Winform Pin
Nouman Bhatti20-Apr-08 20:04
Nouman Bhatti20-Apr-08 20:04 
GeneralProblem sending a public key encrypted string over a socket Pin
anth12320-Apr-08 13:04
anth12320-Apr-08 13:04 
GeneralChanging propertie on other form. Pin
RitchieRich20-Apr-08 12:05
RitchieRich20-Apr-08 12:05 
GeneralRe: Changing propertie on other form. Pin
Christian Graus20-Apr-08 12:11
protectorChristian Graus20-Apr-08 12:11 
GeneralRe: Changing propertie on other form. Pin
cocoonwls20-Apr-08 20:21
cocoonwls20-Apr-08 20:21 
GeneralRe: Changing propertie on other form. [modified] Pin
RitchieRich20-Apr-08 23:48
RitchieRich20-Apr-08 23:48 
GeneralRe: Changing propertie on other form. Pin
cocoonwls22-Apr-08 18:32
cocoonwls22-Apr-08 18:32 
GeneralRender Vista Style ComboBox Pin
Lea Hayes20-Apr-08 10:03
Lea Hayes20-Apr-08 10:03 
GeneralRe: Render Vista Style ComboBox Pin
badtoto24-Dec-08 18:40
badtoto24-Dec-08 18:40 
GeneralRe: Render Vista Style ComboBox Pin
Lea Hayes26-Dec-08 8:16
Lea Hayes26-Dec-08 8:16 
Generalinsert images in rtf file Pin
panoskatws20-Apr-08 7:30
panoskatws20-Apr-08 7:30 
GeneralRe: insert images in rtf file Pin
mav.northwind20-Apr-08 7:44
mav.northwind20-Apr-08 7:44 
GeneralLoading an Icon Resource [modified] Pin
#realJSOP20-Apr-08 4:35
professional#realJSOP20-Apr-08 4:35 
GeneralRe: Loading an Icon Resource Pin
Scott Dorman20-Apr-08 4:50
professionalScott Dorman20-Apr-08 4:50 
GeneralRe: Loading an Icon Resource Pin
#realJSOP20-Apr-08 5:07
professional#realJSOP20-Apr-08 5:07 
GeneralRe: Loading an Icon Resource Pin
Scott Dorman20-Apr-08 5:14
professionalScott Dorman20-Apr-08 5:14 
GeneralRe: Loading an Icon Resource Pin
#realJSOP20-Apr-08 5:41
professional#realJSOP20-Apr-08 5:41 
Well, the GetType() thing just isn't working, but I did figure out how to get the reflection thing to work - I had to use the entire namespace path to get to the embedded files like so (I broke it out to allow easier for me to debug and to allow for formatting here:

string iconName = "MyIcon";
string resolvedName = string.Format("MyAppNamespace.Resources.{0}.ico", iconName);
Stream iconStream = System.Reflection.Assembly.GetExecutingAssembly().GetManifestResourceStream(resolvedName);
m_trayIcon.Icon = new Icon(iconStream);
iconStream.Close();


I'm concerned about not being able to do it with GetType() since so many people see to be doing it that way. I know - I should probably be happy to have found a way to do what I want and leave well enough alone, but I really would like to know what I did wrong there.


"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
-----
"...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001


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.