Method Access

  • Thread starter Thread starter scoffer
  • Start date Start date
S

scoffer

Hi all,

i need to acces the methods of a class using a variable.
Try to explain better my needs:

I have a class with undreds of methods, and i have, in a database, wich of
this method i must use.
Can I access the method with a string variable??

Sample:
My class "class" have this methods "one", "two", "three", "four" and "five".

I've on a database table this record:
UseClass = "three"

Can I access the moethod in a way like "class"."UseClass" so i can invoke
the method "three"??


Help please.
 
scoffer said:
Hi all,

i need to acces the methods of a class using a variable.
Try to explain better my needs:

I have a class with undreds of methods, and i have, in a database, wich of
this method i must use.
Can I access the method with a string variable??

Sample:
My class "class" have this methods "one", "two", "three", "four" and "five".

I've on a database table this record:
UseClass = "three"

Can I access the moethod in a way like "class"."UseClass" so i can invoke
the method "three"??


Help please.
Use the Assembly class to get the module containing the class you want,
then use the module to get the method you want using a string variable.

T
 
Back
Top