In one of our requirement we are facing some issue, wish to know your suggestion.
Details:
We have a Common Static class which we use to read,write and update xml files.
This class consists of static varables that holds XML document and other objects
In some situations where we have more users accessing the site, some XML file content is deleted and replaced with error message or simply delete entire data in XML file.
Questions:
1) Can we use this kind of Static class for read, write or update XML files, having one Static XMLDocument object.
2) Or its suggested to use different XMLDocument object for all read, write or update commands.
saffy
Member
304 Points
365 Posts
Your suggestion on this Scenario
Jan 11, 2012 03:41 AM|LINK
HI,
In one of our requirement we are facing some issue, wish to know your suggestion.
Details:
We have a Common Static class which we use to read,write and update xml files.
This class consists of static varables that holds XML document and other objects
In some situations where we have more users accessing the site, some XML file content is deleted and replaced with error message or simply delete entire data in XML file.
Questions:
1) Can we use this kind of Static class for read, write or update XML files, having one Static XMLDocument object.
2) Or its suggested to use different XMLDocument object for all read, write or update commands.
Please suggest.
jennyortem
Member
306 Points
97 Posts
Re: Your suggestion on this Scenario
Jan 11, 2012 04:32 AM|LINK
Hello,
Static things are always risky. According to me use the second option
saffy
Member
304 Points
365 Posts
Re: Your suggestion on this Scenario
Jan 11, 2012 10:47 AM|LINK
Thank u for your reply.