All pastes #2064251 Raw Edit

reflection

public text v1 · immutable
#2064251 ·published 2011-05-19 08:40 UTC
rendered paste body
System.Reflection.Assembly o = System.Reflection.Assembly.LoadFile("<pathtoEXEfile>");
System.Reflection.FieldInfo fi = o.GetType("<Namespace>.<Class>").GetField("<name of string variable>");
fi.Name; 

this returns <name of string variable> but not the value of that string variable, which i need. if i invoke .getValue(null) i get an exception.