I don't understand your comment at all, there is no marketing here, there is no movie, just a single command called T24 (which is literally defined at the beginning of the code, no need to scroll at all).
This is simply a tool to help the OP do what they requested the ability to do, which I described before the code.
I am also just an end user, in no way affiliated with Autodesk or any reseller (other than use a reseller to purchase our software).
That being said, I will go ahead and attach a video to this post showing how it works.
Now, if you are asking how I get the page size, well I cheat, I don't actually get it from the PDF file, instead, the pertinent sections are:
(defun LM:ssboundingbox ( sel / idx llp ls1 ls2 obj urp )
;; Code by Lee Mac from: http://www.lee-mac.com/ssboundingbox.html
;; Selection Set Bounding Box - Lee Mac
;; Returns a list of the lower-left and upper-right WCS coordinates of a
;; rectangular frame bounding all objects in a supplied selection set.
;; sel - [sel] Selection set for which to return bounding box
(repeat (setq idx (sslength sel))
(setq obj (vlax-ename->vla-object (ssname sel (setq idx (1- idx)))))
(if
(and
(vlax-method-applicable-p obj 'getboundingbox)
(not
(vl-catch-all-error-p (vl-catch-all-apply 'vla-getboundingbox (list obj 'llp 'urp)))
);not
);and
(setq ls1 (mapcar 'min (vlax-safearray->list llp) (cond (ls1) ((vlax-safearray->list llp))))
ls2 (mapcar 'max (vlax-safearray->list urp) (cond (ls2) ((vlax-safearray->list urp))))
);setq
);if
);repeat
(if (and ls1 ls2) (list ls1 ls2))
);LM:SSBoundingBox
Then you can attach the PDF and get the boundary of the most recently inserted page using the following:
(setq *Single* nil
*Single* (ssadd)
SingleBound (LM:SSBoundingBox *Single*)
LowerLeft (nth 0 SingleBound)
UpperRight (nth 1 SingleBound)
Width (- (car UpperRight) (Car LowerLeft))
Height (- (cadr LowerLeft) (cadr UpperRight))
);setq
(if (< Width 0)
(setq Width (* Width -1))
)
(if (< Height 0)
(setq Height (* Height -1))
)
This will specifically get you the width and height of the page. I have recently been told that there may be a way to get it from the PDF file itself, but I haven't tried that approach as of yet, as this accounts for the entire outline of the PDF and the other may not.
I also updated my previous post to make the code an attachment instead of inline in the reply.