Hide WPF elements in Visual Studio designer

后端 未结 7 1857
暗喜
暗喜 2020-11-30 08:39

I have a WPF form which basically looks like this:


  
    
      [content shown during normal operation]
             


        
7条回答
  •  旧巷少年郎
    2020-11-30 09:16

    Starting from VS2012 you can just use the Blend namespace IsHidden attribute:

    • add if not already present xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    • put d:IsHidden="true" on element you want to hide at design time only

提交回复
热议问题