You did not have Tyrogue's Attack and Defence stats equal. If they were uneven and your Tyrogue's stats were Attack > Defence or Defence > Attack, you won't get Hitmontop. X Defends do not raise the base Defence stat, which is probably what you mistook for the Iron vitamin item which raises Tyrogue's Defences EVs by 10. X Defends only raise a stat for the battle it was used in, and don't raise EVs. In depth:
X Defendes do not raise a Pokemon's base stat; they only raise it during the battle. Once you are out of the battle, you will not have the stat ups anymore. The only way to evolve Tyrogue into Hitmontop is to have equal Defence and Attack stats at Level 20, known as base stats, which are the stats you see in your Pokemon's summary. You can increase these stats by levelling up, though what you gain from it is determined by Effort Values. To raise your Pokemons Defence EVs, sucessfully defeat a Pokemon with a Defence EV yeild, use Wing items or Vitamins.
Even if the X items did raise the base stat, you probably would have got Hitmonchan due to a higher Defence stat than Attack.
So basically you got the method wrong. X Defends will not make your Pokemon evolve, though with the right and equal dose of stats in Defence and Attack, you will get Hitmontop.