D
Dom
I did the following in the Form1:
private static DIctionary<string,object> m_Data;
private Dictionary <string,object> Data {get {return m_Data;} set
{m_Data=value;}}
private void Form1_Load()
{
bool Status = GetData (ref Data);
...
}
The compiler complained that I can't use a property with "ref", and I
think I know why -- it is using ref with the result of a function.
But what is the proper way?
I ended up with: bool Status = GetData (ref m_Data)
and then used "Data" elsewhere. This must come up often. Is there a
preferred way?
Dom
private static DIctionary<string,object> m_Data;
private Dictionary <string,object> Data {get {return m_Data;} set
{m_Data=value;}}
private void Form1_Load()
{
bool Status = GetData (ref Data);
...
}
The compiler complained that I can't use a property with "ref", and I
think I know why -- it is using ref with the result of a function.
But what is the proper way?
I ended up with: bool Status = GetData (ref m_Data)
and then used "Data" elsewhere. This must come up often. Is there a
preferred way?
Dom