title: Recursion algorithm Stops running after finding the first Leaf node
body: <p>I do apology in advance if there are many variables in the following code sample that their "types" is not clear to you, it is a big library, I just can't put all of that in here, so think of it at high-level, and the name of the variables is kind of helpful too...</p>
  
  <p>Problem: A "concept" can have many "relations". Each of those relations can also have many concepts, For example like a father and child, a father has many children, a child may itsself be a father and has more children ,etc...
  So I want to pass the root father and get all the hierarchy and write it to a file ...</p>
  
  <p>The high-level code I am using is this, THE PROBLEM IS THAT it Crashes by a Null exception when it gets the child that has no more children. So its object is null in this line:</p>
  
  <pre><code>oUCMRConceptReltn = moTargetConceptList.ConceptReltns.get_ItemByIndex(i, false);
  </code></pre>
  
  <p>So I thought well let's put a not null check around it, yeah fixes the crash BUT after it sees the first leafe, it doesn't go further and algorithm stops. 
  So Something is wrong with the way I am calling recursion, but can't figure it out. </p>
  
  <pre><code>private void MyLoadMethod(string sConceptCKI)
  {
      UCMRConceptLib.UCMRConceptLoadQual oUCMRConceptLoadQual = new UCMRConceptLib.UCMRConceptLoadQual();
  
      //Fill out UCMRConceptLoadQual object to get new list of related concepts
      moTargetConceptList.Load(oUCMRConceptLoadQual;
  
      // WHEN IT IS ZERO, THERE ARE NO MORE CHILDREN.
      int numberofKids = moTargetConceptList.ConceptReltns.Count();
      if (numberofKids == 0)
          return ;
      for (int i = 1; i &lt;= numberofKids; i++)
      {
          oUCMRConceptReltn = moTargetConceptList.ConceptReltns.get_ItemByIndex(i, false);
  
              //Get the concept linked to the relation concept
              if (oUCMRConceptReltn.SourceCKI == sConceptCKI)
              {
                  oConcept = moTargetConceptList.ItemByKeyConceptCKI(oUCMRConceptReltn.TargetCKI, false);
              }
              else
              {
                  oConcept = moTargetConceptList.ItemByKeyConceptCKI(oUCMRConceptReltn.SourceCKI, false);
              }
  
              //write its name to the file...now recursion: go and find its children.
              builder.AppendLine("\t" + oConcept.PrimaryCTerm.SourceString);
              MyLoadMethod(oConcept.ConceptCKI);
      }
      return ;
  }
  </code></pre>