I am having trouble calling the method I made.
The method I refer to is as follows:
public bool GetValue(string column, out object result)
{
result = null;
if (this._values.ContainsKey(column))
{
result = Convert.ChangeType(this._values[column], result.GetType());
return true;
}
return false;
}
I am calculating a method using this code, but I get a compiler error
int age;
a.GetValue("age", out age as object)
The argument ref or out must be an assignable variable.
Has anyone else had this problem, or am I just doing something wrong?
source
share