You can’t set Quality Gate conditions on specific rules. What you can do is set conditions on categories of rules. For instance, I see that by default S4462 is a Blocker. So you could set a condition on the number of Blocker issues.
Thanks for your answer. To make it clear, the condition is not blocking the quality gate because Sonarqube does not see this rule on that snipped of code, there is no issue thrown in any of our applications. 0 issues on rule csharpsquid:S4462 in arround 3/4 million lines of code, thats a llitlebit strange.