If you have a really complicated init that you need to run for a const
member, you can write a static method which returns the result.
private static short[] InitTest() {
short[] res = null;
// do lots of complicated stuff here
return res;
}
public const short[] test = InitTest();
--Don
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"babylon" <am***@hotmail.com> wrote in message
news:Os**************@TK2MSFTNGP12.phx.gbl...
I can't do
public const short[] test = new short[]{1000,2000,3000};
any suggestions?
thx