title: XPath "how many elements in node?" with Microsoft EXCEL
body: <p>I'm trying to use Microsoft Excel's FILTERXML function to grab data from an XML form.</p>
  
  <p>I'm not quite sure why I'm unable to get a number response when I use certain XPath arguments.</p>
  
  <p>Here's my XML:</p>
  
  <pre><code>&lt;result&gt;
  &lt;status&gt;1&lt;/status&gt;
  &lt;num_results&gt;1&lt;/num_results&gt;
  &lt;total_results&gt;500&lt;/total_results&gt;
  &lt;results_remaining&gt;499&lt;/results_remaining&gt;
  &lt;matches&gt;
      &lt;match&gt;
          &lt;radiant_team_id&gt;0&lt;/radiant_team_id&gt;
          &lt;dire_team_id&gt;0&lt;/dire_team_id&gt;
          &lt;players&gt;
              &lt;player&gt;
                  &lt;account_id&gt;141684701&lt;/account_id&gt;
                  &lt;player_slot&gt;0&lt;/player_slot&gt;
                  &lt;hero_id&gt;0&lt;/hero_id&gt;
              &lt;/player&gt;
              &lt;player&gt;
                  &lt;account_id&gt;4294967295&lt;/account_id&gt;
                  &lt;player_slot&gt;1&lt;/player_slot&gt;
                  &lt;hero_id&gt;0&lt;/hero_id&gt;
              &lt;/player&gt;
              &lt;player&gt;
                  &lt;account_id&gt;4294967295&lt;/account_id&gt;
                  &lt;player_slot&gt;2&lt;/player_slot&gt;
                  &lt;hero_id&gt;0&lt;/hero_id&gt;
              &lt;/player&gt;
          &lt;/players&gt;
        &lt;/match&gt;
     &lt;/matches&gt;
  &lt;/result&gt;
  </code></pre>
  
  <p>I'm trying to use this XPath argument to count how many players pop up in a dynamic API that refreshes an XML form every so ofter. The player count varies from 0-10.</p>
  
  <pre><code>/result/matches/match/players[count(player)]
  </code></pre>
  
  <p>I get a #!VALUE error. Here's the MS Excel function argument I use:</p>
  
  <pre><code>=FILTERXML($A$2,"/result/matches/match/players/player[count(player)]")
  </code></pre>
  
  <p>Both arguments fail. Is there a way I can report how many player elements exist in the XML form by reporting to another cell in MS Excel?</p>