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

Getting the entire screen region of a page in print preview in Microsoft Word

$
0
0

I'm trying to identify the entire page view in print area. Using the UIAutomation framework, I can drill down when in Print Preview mode like so:

  1. Word window (ClassName = OpusApp)
  2. Pane (ClassName = _WwF)
  3. Pane (ClassName = _WwB)
  4. Document (ClassName = _WwG)
  5. Page (custom control with AutomationID = UIA_AutomationID_Word_Page_#)

Object #4 represents an area the entire width of the application (excluding scrollbars) the includes the page as well as an area of gray space (the red box)

Object #5 represents just the content on the page, excluding the margins. (the green box)

Is there a way to grab the object representing the actual page with the margins (the blue box)?


Viewing all articles
Browse latest Browse all 585

Trending Articles



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