Works is works...Salvation is by grace.
The selective reading of Scripture by the Reformation and her children is really trite and tiring and refuted many times. It's not even an issue between Lutherans and Catholics any longer. So I'll leave it at that.
Regarding the Papacy and Pelagianism, this might be instructive: