How could I get the string value from a hashtable without calling toString() methode?
example: my class:
public class myHashT : Hashtable
{
public myHashT () { }
...
public override object this[object key]
{
get
{
return base[key].ToString(); <--this doesn't work!
}
set
{
base[key] = value;
}
}
}
In an other class:
myHashT hT;
string test = hT["someKey"];
it works with hT["someKey"].toString();
but I need it without calling ToString()
and without casting to (string).