Correct event for detecting a change in the size of a page

Started by ImAPictureFormat, January 09, 2020, 08:09:44 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ImAPictureFormat

Hi,

I have an Application.CellChanged handler set up that sets shape data, moves children of the shape whose cell caused was changed, etc., when a shape moves. In the case I'm looking at, I have a shape that borders a page break. When I move the shape over the page break, it causes CellChanged events to fire for 1) the PinX and PinY locations of the shape I moved, and 2) for the PageWidth and PageHeight cells of the PageSheet because of the page size change. In my code I need to detect the change in the page width and height, but the CellChanged event for PageSheet.PageWidth and PageSheet.PageHeight fires after the CellChanged for Shape.PinX and Shape.PinY.

I would like to be able to detect the page width/height change before the CellChanged event for the shape's PinX/Y.

From what I've found by googling, the CellChanged event is the right way to capture the page width/height change, but is there a better way to detect the page width/height change?
Alternatively, instead of letting Visio resize the page, could I instead programatically resize it after I handle the CellChanged for the shape PinX/Y?

Thank you!

Browser ID: smf (possibly_robot)
Templates: 4: index (default), Display (default), GenericControls (default), GenericControls (default).
Sub templates: 6: init, html_above, body_above, main, body_below, html_below.
Language files: 4: index+Modifications.english (default), Post.english (default), Editor.english (default), Drafts.english (default).
Style sheets: 4: index.css, attachments.css, jquery.sceditor.css, responsive.css.
Hooks called: 130 (show)
Files included: 34 - 1306KB. (show)
Memory used: 1047KB.
Tokens: post-login.
Cache hits: 13: 0.00145s for 26,597 bytes (show)
Cache misses: 2: (show)
Queries used: 16.

[Show Queries]