Click here to Skip to main content
15,917,795 members
Home / Discussions / C#
   

C#

 
QuestionHow often? Pin
matthias s.2-Aug-04 23:20
matthias s.2-Aug-04 23:20 
AnswerRe: How often? Pin
leppie3-Aug-04 1:33
leppie3-Aug-04 1:33 
GeneralDoubt in Phil Wright's TabControl Pin
Archana19772-Aug-04 22:14
Archana19772-Aug-04 22:14 
GeneralRe: Doubt in Phil Wright's TabControl Pin
leppie3-Aug-04 1:43
leppie3-Aug-04 1:43 
GeneralRe: Doubt in Phil Wright's TabControl Pin
Archana19773-Aug-04 2:27
Archana19773-Aug-04 2:27 
GeneralRe: Doubt in Phil Wright's TabControl Pin
Nick Parker3-Aug-04 3:29
protectorNick Parker3-Aug-04 3:29 
GeneraldlThread exception handler Pin
LorenzoDV2-Aug-04 22:02
LorenzoDV2-Aug-04 22:02 
GeneralRe: dlThread exception handler Pin
leppie3-Aug-04 1:46
leppie3-Aug-04 1:46 
GeneralAccess is denied Pin
Anonymous2-Aug-04 22:00
Anonymous2-Aug-04 22:00 
GeneralCulture extrange behavior Pin
Jose Vicente2-Aug-04 21:53
Jose Vicente2-Aug-04 21:53 
GeneralRe: Culture extrange behavior Pin
Norman-Timo3-Aug-04 1:20
Norman-Timo3-Aug-04 1:20 
GeneralRe: Culture extrange behavior Pin
Jose Vicente3-Aug-04 3:14
Jose Vicente3-Aug-04 3:14 
QuestionHow to save status of runtime controls? Pin
sachinkalse2-Aug-04 21:24
sachinkalse2-Aug-04 21:24 
AnswerRe: How to save status of runtime controls? Pin
Norman-Timo3-Aug-04 0:52
Norman-Timo3-Aug-04 0:52 
GeneralIdentify max no of child nodes for a node in XML Pin
saud_a_k2-Aug-04 20:49
saud_a_k2-Aug-04 20:49 
GeneralRe: Identify max no of child nodes for a node in XML Pin
Norman-Timo3-Aug-04 1:06
Norman-Timo3-Aug-04 1:06 
GeneralRe: Identify max no of child nodes for a node in XML Pin
saud_a_k3-Aug-04 1:35
saud_a_k3-Aug-04 1:35 
GeneralRe: Identify max no of child nodes for a node in XML Pin
Norman-Timo3-Aug-04 1:54
Norman-Timo3-Aug-04 1:54 
Ok if I understand it correctly:

You want to have first level Nodes and especially that one with the most child nodes?
In your case the nodes with "customer id..."?

But than you can take the first part from my example (the part until you have the 'doc' XML file and your root node.

Than you can do it in an analogue way:

***************************************************
int maxChildCount = 0;
XmlNode mostChildNode = null;

actNode = root.FirstChild; // then you have the first customer node!

while (actNode != null)
{
if (maxChildCount < actNode.ChildNodes.Count)
{
maxChildCount = actNode.ChildNodes.Count;
mostChildNode = actNode;
}

actNode = actNode.NextSibling;
}

*************************************************

The reason that my program is not working is maybe the fact, that I typed in the source directly in this reply-form (sorry).

But you are certainly able to correct compiler errrors, I think. (if there are some)

I think with these line of code you have your solution, if I understand you right.

I´m sorry if I´m not correct again.

Norman-Timo


Edited:
By the way with what html tags can I highlite the code sources?
GeneralRe: Identify max no of child nodes for a node in XML Pin
saud_a_k3-Aug-04 2:38
saud_a_k3-Aug-04 2:38 
GeneralRe: Identify max no of child nodes for a node in XML Pin
leppie3-Aug-04 1:52
leppie3-Aug-04 1:52 
GeneralRe: Identify max no of child nodes for a node in XML Pin
saud_a_k3-Aug-04 2:31
saud_a_k3-Aug-04 2:31 
GeneralProblem accessing array of objects Pin
crushinghellhammer2-Aug-04 20:33
crushinghellhammer2-Aug-04 20:33 
GeneralRe: Problem accessing array of objects Pin
misterbear2-Aug-04 23:22
misterbear2-Aug-04 23:22 
GeneralRe: Problem accessing array of objects Pin
Stefan Troschuetz2-Aug-04 23:35
Stefan Troschuetz2-Aug-04 23:35 
QuestionIs there an MMC Snap-in Designer for .NET environment? Pin
zzzhouzhou2-Aug-04 18:34
zzzhouzhou2-Aug-04 18:34 

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.