Parameter passing

  • Thread starter Thread starter Jon
  • Start date Start date
J

Jon

Hello all.

I have a method that accepts a parameter, but this
parameter can potentially be of any type (string, int,
etc). What would be there best way to implement this? Have
an Overloading method for each type?

Thanks all,

Jon.

P.S I'm using C#
 
Try passing the parameter as an object and then convert it
to the appropriate datatype.
 
Back
Top