Henry IV's friendship was of essential importance to the Papacy two years later, when Alfonso II, Duke of Ferrara, died childless (27 October 1597), and the Pope resolved to attach the stronghold of the Este family to the states of the Church. Though Spain and the Emperor Rudolf II encouraged Alfonso II's illegitimate cousin, Cesare d'Este, to withstand the Pope, they were deterred from giving him any material aid by Henry IV's threats, and a papal army entered Ferrara almost unopposed.