Khaniya wrote:
but I need it with Conditional
This makes absolutely zero sense. It is a non question. Checking the value of DEBUG with #if works on the same level that DEBUG is defined. In other words, the only way to do this is to add a method that returns a bool and use #if DEBUG to have it return true or false correctly. That is just wrapping the check, it does not change the nature of the check you need to make.