Is it possible to use variables strings to change member calls in your code?
For example... say you have a few members in your class called
RunSomthing_Start()
RunSomthing_Process()
RunSomthing_End()
is there a way to call them with somthing like this in code elsewhere in your project?
action = "_Start";
classObject.RunSomething+action();
action = "_Process";
classObject.RunSomething+action();
action = "_End";
classObject.RunSomething+action();
I know you can use parameters.. like
action = "_Start";
classObject.RunSomething(action);
action = "_Process";
classObject.RunSomething(action);
action = "_End";
classObject.RunSomething(action);
This is more just a curiosity question... like can you use string functions like you have in Console.Write(); to append stuff onto the name of Functions and Variables?
int object_+getObjectID() = someValue.
So the actual variable has a unique name based on the object.. not just the value in the variable.