Easiest way to combine a dataset and other data in a single file?
Posted
by Tim Gradwell
on Stack Overflow
See other posts from Stack Overflow
or by Tim Gradwell
Published on 2010-05-28T13:48:41Z
Indexed on
2010/05/28
13:52 UTC
Read the original article
Hit count: 243
I have a dataset in C# which I can serialise using dataset.WriteXml(filename);
but I want the file to contain other data as well (essentially some meta data about the dataset).
I could add another table to the dataset which contained the metadata, but I'd prefer to keep it separate, if at all possible.
Essentially I think I want to create a 'combination of files' file, that looks something like this:
size_of_file1
file1
size_of_file2
file2
... etc
Then, I'd like to load the file into memory, and split the file into separate streams, so that I can feed the dataset into dataset.ReadXml(stream);
and the metadata into something else.
Sound possible? Can anyone tell me how I can do it?
Thanks
Tim
© Stack Overflow or respective owner