Cardinal Ricci was accepted as a visitor and Christian advocate to the Imperial court in the declining years of the Ming Dynasty. His approach was that the Chinese people always believed in God and he was only presenting a more perfect manifestation of God. Of course, the Pope still had a preeminent role -- far from acceptable to the Emperor. His muted Christian message was also not acceptable to the Dominican and Franciscan Orders of the Catholic Church and they encouraged the Pope to outlaw his ministry.
Despite all, Ricci established a number of Catholic constituencies in China, not necessarily at the capitol. Interestingly, these continued as functioning Christian communities for more than 300 years, from his time until the 1920’s. A number Chinese from these Christian congregations came into prominence as leaders of government and business activities in Western-Chinese relationships at that time. (Dr. Carol Hamrin of George Mason University provides specifics in her recent books - Salt and Light -- Vols. 1& 2))
The persistence of Christianity in China makes two important points about China over these Chinese centuries. The first is that Chinese society was, and recently still is, both tolerant and accepting, of religious practice divergent from the majority practices. Other examples are the persistence Nestorian Christians, Jewish enclaves and Moslem communities in areas where they are a small minority. A second point is that members of the few historic Christian communities rose to leadership roles in government and business far out of proportion to their statistical significance in the broader Chinese society.