To ensure compatibility, you should check the transmission identification numbers on both transmissions. These numbers will tell you the specific type and version of the transmission. You'll need to compare these numbers to be absolutely certain they are interchangeable.
Without knowing the specific transmission codes, it's impossible to say for sure. Using the wrong transmission could lead to serious problems. Consulting a Ford parts catalog or a reputable transmission shop is highly recommended before attempting the swap.