Quantcast
Channel: Windows Desktop Development for Accessibility and Automation forum
Viewing all articles
Browse latest Browse all 585

TransformPattern.Resize is closing window upon resize

$
0
0

I am using the UIA TransformPattern.Resize pattern to resize a window. It works, but closes the window as soon as the resize shows. Is this intentional?

Here's the code that does the resize:

        internal static int Resize(AutomationElement control, double width, double height)
        {
            TransformPattern pat =
                (TransformPattern) CommonUIAPatternHelpers.CheckPatternSupport(TransformPattern.Pattern, control);
            if (pat.Current.CanResize)
            {
                pat.Resize(width, height);
                return 0;
            }
            return -1;
        }
As I said, the resize works, but it then closes the window (on both a WinForm and a WPF Form).


Viewing all articles
Browse latest Browse all 585

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>