Thanks for such a quick response Adam. That is certainly a simple and
workable solution. Since you've answered my question the following is
purely academic, maybe you can shed some light. Can a shallow/deep copy be
made of a .net object? Not a copy of my own object but a copy an object
provided by the .net run-time, such as asp.net's response object.
Thanks again for the help.
"Adam Barker" <adam@NO******@q-state.co.NO_SPAM.uk> wrote in message
news:ua**************@TK2MSFTNGP09.phx.gbl...
NameValueCollection source = Request.Form;
NameValueCollection dest = new NameValueCollection();
foreach(string sKey in source.Keys)
dest.Add(sKey, source[sKey]);
"Andrew" <an*********@hotmail.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...I would like to make a copy of the Request.Form collection object. A
shallow copy is fine. Request.Form is read-only and I'd like a copy to
work with. It seems MemberwiseClone() is protected. I'd be very
appreciative if someone would point me in he right direction.
Thank you,
Andrew