Click here to Skip to main content
15,889,096 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: Need help generating tree structure. Pin
Robert Rohde7-Jan-05 21:46
Robert Rohde7-Jan-05 21:46 
GeneralRe: Need help generating tree structure. Pin
Ritesh12349-Jan-05 23:28
Ritesh12349-Jan-05 23:28 
GeneralConverting a HEX value to a DateTime Pin
Stanimir_Stoyanov7-Jan-05 0:18
Stanimir_Stoyanov7-Jan-05 0:18 
GeneralRe: Converting a HEX value to a DateTime Pin
Mike Dimmick7-Jan-05 2:30
Mike Dimmick7-Jan-05 2:30 
Generalwhich testing tool is better Pin
montu33776-Jan-05 23:08
montu33776-Jan-05 23:08 
GeneralCompiling VC++ application on VC7 Pin
_Tom_6-Jan-05 2:18
_Tom_6-Jan-05 2:18 
GeneralAdvice needed for how to use XML DOM Pin
John Guin5-Jan-05 7:19
John Guin5-Jan-05 7:19 
GeneralRe: Advice needed for how to use XML DOM Pin
Charlie Williams6-Jan-05 5:40
Charlie Williams6-Jan-05 5:40 
JohnGuin wrote:
I read all the best practice documents I could find on MSDN, but they only addressed the plusses and minuses of using the DOM vs. SAX, and gave no guidance on the best way of implementing a class using the DOM.

That's not really a surprise, as I don't think this has a lot to do with XML DOM. It's more of a design question.

Anyway, I would make this decision based on how much the XmlDocument gets used. If it is used extensively throughout your applicaton, I might keep it alive for the life of the object in question. If, on the other hand, it is used only at startup and stutdown, for example, I would instantiate it as needed.

Every time it is loaded, it takes a certain amount of time to read it from disk and parse the XML. That's not something I would want happening constantly. Nor would I want to spend my memory on something that's just sitting there and not being used. Either could be correct, depending on the circumstances.



Charlie

if(!curlies){ return; }
GeneralInfuriating, Costly Exception Handling Delay Pin
JMPurcell4-Jan-05 18:53
JMPurcell4-Jan-05 18:53 
GeneralRe: Infuriating, Costly Exception Handling Delay Pin
JMPurcell6-Jan-05 8:14
JMPurcell6-Jan-05 8:14 
GeneralRe: Infuriating, Costly Exception Handling Delay Pin
Rob Graham6-Jan-05 9:41
Rob Graham6-Jan-05 9:41 
GeneralRe: Infuriating, Costly Exception Handling Delay Pin
JMPurcell6-Jan-05 11:36
JMPurcell6-Jan-05 11:36 
GeneralRe: Infuriating, Costly Exception Handling Delay Pin
Colin Angus Mackay7-Jan-05 0:04
Colin Angus Mackay7-Jan-05 0:04 
GeneralRe: Infuriating, Costly Exception Handling Delay Pin
JMPurcell7-Jan-05 7:52
JMPurcell7-Jan-05 7:52 
Generalserial com port communication! Pin
Member 16267074-Jan-05 12:11
Member 16267074-Jan-05 12:11 
GeneralRe: serial com port communication! Pin
Ritesh12347-Jan-05 3:27
Ritesh12347-Jan-05 3:27 
GeneralXML encoding losing special Characters Pin
kikilala4-Jan-05 10:19
kikilala4-Jan-05 10:19 
GeneralPocket PC Application Pin
vksrisridhar4-Jan-05 1:29
vksrisridhar4-Jan-05 1:29 
QuestionWinForms Form with a Win32 Window as a Parent? Pin
Uwe Keim3-Jan-05 2:28
sitebuilderUwe Keim3-Jan-05 2:28 
AnswerRe: WinForms Form with a Win32 Window as a Parent? Pin
Uwe Keim3-Jan-05 18:50
sitebuilderUwe Keim3-Jan-05 18:50 
GeneralRedirecting Mails from one domain to another in Exchange server Pin
Ashutosh j2-Jan-05 20:41
Ashutosh j2-Jan-05 20:41 
GeneralRe: Redirecting Mails from one domain to another in Exchange server Pin
Mike Dimmick6-Jan-05 12:59
Mike Dimmick6-Jan-05 12:59 
Generalencapsulate a program Pin
Anonymous2-Jan-05 3:23
Anonymous2-Jan-05 3:23 
GeneralRe: encapsulate a program Pin
zagzagzag3-Jan-05 1:04
zagzagzag3-Jan-05 1:04 
General.NET Pocket Framework Pin
zagzagzag1-Jan-05 11:55
zagzagzag1-Jan-05 11:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.