The only examples I am aware of are the Samurai after the establishment of the Tokugawa Shogunate, and to a limited extent, the Ottoman Janissary armies into the 1500's, but these were results of particular circumstances.
The Samurai were actually very enthusiastic in their adoption and use of firearms. Perhaps the most striking example was the Battle of Nagashino, where the traditional armies of Katsuyori Shingen were destroyed by mass volley fire from the forces of Tokugawa Ieyasu and Oda Nobunaga.
These sorts of battles were early examples of the "Infantry Revolution" in Japan, where weapons and tactics were being introduced to allow relatively untrained Infantrymen to take the field and contend with highly trained Samurai warriors. In Europe, the process eventually swept away knights and the Feudal system, but Japan was more isolated and insular due to the island nature of the country. Once the Tokugawa Shogunate was firmly established, a process of disarming the peasants was rapidly undertaken to prevent the overthrow of the established social and political order, and firearms essentially passed from Japanese history until the arrival of the Americans and the Meiji restoration.
The Ottoman Janissaries are a slightly different case. The Ottoman Empire, despite its size and resources, was actually rather poor in terms of deploying resources. While the Ottomans were well aware of gunpowder, artillery and firearms, they did not have the same ability to actually make cannon and firearms, often buying them from their Western rivals like Genoa or Venice (through black markets or renegade Western traders). During the Battle of Lepanto, the Christian fleet was armed with cannon and the boarding parties armed with the match and wheel locks common to the period, while the Janissaries embarked on the Ottoman fleet were armed with the deadly recurve bow.
In practical terms, once the ships were closing in, the Ottomans could unleash hails of arrows with greater speed and accuracy than the Christian soldiers could reply. The problem was while the Christian soldiers could be shielded by light wooden barriers, coils of rope and so on, their shot could penetrate similar protective barriers on the Ottoman ships. An arquebus could deliver 1000j of energy with each shot, while a typical arrow delivered between 100-200j of energy.
The other issue (which plagued the Samurai and European knights) was it took a lifetime of training to prepare Jamissaries, and the massive casualties from the battle of Lepanto would take a generation to make good, you could train people to use firearms in a matter of weeks. (English Longbowmen also took a lifetime of training, which explains why despite their fearsome reputation in the 100 years war, longbows were not commonly adopted by European armies).
So in order to suppress the use of firearms, crossbows and pikes (the ,major enablers of the Infantry Revolution), you would need to have the existing Feudal social order which supported Knights, Samurai, Janissaries or similar classes of highly trained fighting men, an understanding of the danger firearms and simplified but effective mass infantry tactics posed to their military and social status, and the ability to limit or effectively ban the use of firearms (lie the Japanese) or the inability to create them on a mass scale (like the Ottomans).