Is there an #IF DEBUG for Asp.net markup?

前端 未结 5 1414
野的像风
野的像风 2020-12-05 17:07

Can I do something like this in the markup of an asp.net page, based off the \"Define DEBUG constant\" setting?

#IF (DEBUG) THEN
  

        
5条回答
  •  北海茫月
    2020-12-05 17:52

    <% #if DEBUG %> You're in debug mode <% #else %> Mmm... No, I think you're not in debug mode <% #endif %>

    Note that you cannot assign the same ID for those text boxes.

    Also note that DEBUG is true when it is set so in web.config:

    
    

提交回复
热议问题