N
newscorrespondent
C++
void SomeClass::SomeRoutine (void)
{ QuestionClass abc(__FUNCTION__);
}
In C++ when "SomeRoutine" runs the QuestionClass gets the name of the
current function. It seems like I should be able to get this using
reflection with C# but I have not been able to figure out how. Is there a
way to do this?
When this routine ends the destructor for QuestionClass is run. Is there a
way in C# to insure that the class is destroyed in a similar fashion. The
best way I can see is to make the class implement IDisposable and use a
using clause wrapping the entire contents of the routine. Is there a better
way?
Thanks
void SomeClass::SomeRoutine (void)
{ QuestionClass abc(__FUNCTION__);
}
In C++ when "SomeRoutine" runs the QuestionClass gets the name of the
current function. It seems like I should be able to get this using
reflection with C# but I have not been able to figure out how. Is there a
way to do this?
When this routine ends the destructor for QuestionClass is run. Is there a
way in C# to insure that the class is destroyed in a similar fashion. The
best way I can see is to make the class implement IDisposable and use a
using clause wrapping the entire contents of the routine. Is there a better
way?
Thanks