Method Access

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • scoffer

    #1

    Method Access

    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"."UseCla ss" so i can invoke
    the method "three"??


    Help please.


  • tomb

    #2
    Re: Method Access

    scoffer wrote:
    [color=blue]
    >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"."UseCla ss" so i can invoke
    >the method "three"??
    >
    >
    >Help please.
    >
    >
    >
    >[/color]
    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

    Comment

    Working...