In 1635 King Abu al-Mafakhir named his son Prince Pekik (Abu al-Ma'ali Ahmad) as his co-reign. In the next year a peace treaty with Batavia was signed and ratified later in 1639. In 1636, the sovereign sent envoy to Mecca for the first time, and two years later the diplomatic delegation returned with the prestigious title of "sultan" bestowed by the Grand Shareef of Mecca upon the king of Banten. This was the first sultan title officially bestowed by Mecca upon the king of Java, which much to the dismay of the powerful King Hanyokrokusumo of Mataram that subsequently also sent envoys to Mecca to acquire this much coveted honorific title of Islamic world.