Next came Mary's sister Princess Anne and her descendants. Finally, the descendants of William by any future marriage were added to the line of succession. Only Protestants were allowed to succeed; those who married Roman Catholics were excluded. After Mary II died in 1694, her husband continued to reign alone until his own death in 1702. The line of succession provided for by the Bill of Rights was almost at an end; William and Mary had no children and Princess Anne's children had died. Parliament passed the Act of Settlement 1701. The Act maintained the provision of the Bill of Rights whereby William would be succeeded by Princess Anne and her descendants, and thereafter by his own descendants from future marriages. The Act declared that they would be followed by James I & VI's granddaughter Sophia, Electress Dowager of Hanover (the daughter of James's daughter Elizabeth Stuart), and her heirs. As under the Bill of Rights, non-Protestants and those who married Roman Catholics were excluded. Because Sophia was a foreign citizen, Parliament passed the Sophia Naturalization Act 1705 to make her and her descendants English and therefore eligible for the throne. Upon William's death, Anne became Queen of England, Scotland and Ireland. Because the Parliament of England settled on Sophia as Anne's heir-presumptive without consulting Scottish leaders, the Estates of Scotland retaliated by passing the Scottish Act of Security. The Act provided that, upon the death of Anne, the Estates would meet to select an heir to the throne of Scotland, who could not be the same person as the English Sovereign unless numerous political and economic conditions were met. Anne originally withheld the Royal Assent, but was forced to grant it when the estates refused to raise taxes and sought to withdraw troops from the queen's army. England's Parliament responded by passing the Alien Act 1705, which threatened to cripple Scotland's economy by cutting off trade with them. Thus, Scotland had little choice but to unite with England to form the Kingdom of Great Britain in 1707; the crown of the new nation (along with the crown of Ireland) was subject to the rules laid down by the English Act of Settlement. Hanoverians and Windsors Anne was predeceased by Sophia, Electress Dowager of Hanover, and was therefore succeeded by the latter's son, who became George I in 1714. Attempts were made in the risings of 1715 and 1745 to