Hi,
First of all, you will have to create and fill it at least once :)
What you could do is serialize the collection to a file, then include this
file in your project as an "embedded resource" doing so will put the file
inside your main output ( .exe or .dll ) then at runtime you can access it
and recreate your collection from it. easier and faster that create the
collection all the time.
how do you store your table? cause you will need a class that support
serialization, take a look at ISerializable interface and
SerializableAttribute , there are articles in MSDN too that you should read.
cheers,
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Serj Kondryukov" <ks*@tornado.nsk.ru> wrote in message
news:OD**************@TK2MSFTNGP09.phx.gbl...
I am novice in C#. I did write on C++ before.
In my current program i need to use big constant table. Each string is a
some struct what contain following fields:
MyEnum f1;
MyEnum f2;
bool f3;
double[] f4;
ushort[] f5;
Fields f1 and f2 have enum type what i define early. Last two fields is a
arrays by 9 items. Now i need get some f1, f2 and f3 values + some index
and find corresponding row in my table and corresponding index ushort and
double from last fields.
I don't want to put my table in external file. What offers do you have ? I
have some myself ideas but may be i don't know a some C# specifical
features for it.
Thank you.