1

I have a WPF page with validation rules. This page has 2 grids - 1 that's shown by default, and another that can be toggled to show via an animation (a button is pressed, and the second grid's height is animated to show over top of the 1st grid, and the 1st grid is disabled).

My problem is this: I have validation rules on the first grid, and when one of them fails, a red border appears around the control (as it should). But when the second grid is overlayed on top of the first, I can still see the red border from the first grid, even though I set the first grid's Visibility to Hidden.

I've tried setting the Panel.ZIndex property on both so that I'm sure the second grid is showing up in front of the first. Any ideas?!

Mark Carpenter
  • 17,445
  • 22
  • 96
  • 149
  • The Grid doesn't have a border property, so it may be that you have another element (maybe a Border) that isn't in scope and being hidden. Could you post some example code illustrating your problem? – Jeff Wain Jul 08 '09 at 14:42

1 Answers1

1

This Question contained a perfect solution to my problem! No more artifacts!

Community
  • 1
  • 1
Mark Carpenter
  • 17,445
  • 22
  • 96
  • 149