I use these (2) that I cobbled together...not the prettiest, nor does it work everytime...I haven't had time to make them better, but they might lead you in the right direction:
;==============================================
;SET VIEWPORT BASED ON OBJECTS (1-1/2" = 1'-0")
;==============================================
(defun C:DomVIEWPORT_SetViewPortProfile ()
(setq CurLayOut (getvar 'ctab))
(command "pspace")
(princ "\n*** SETVIEWPORT: PROFILE BY OBJECTS (1-1/2) ***")
(setq ViewP (entsel "\nSelect VIEWPORT to modify: "))
(setq ViewPEnt (entget (car ViewP)))
(setq ViewPID (cdr (assoc 69 ViewPEnt)))
(if Block
()
(progn
(setvar 'tilemode 1)
(setq Block (ssget))
(setvar 'ctab CurLayOut)
);progn
);if
(command "mview" "lock" "off" ViewP "")
(command "mspace")
(setvar "cvport" ViewPID)
(command "zoom" "object" Block "")
(command "zoom" "scale" "1/8xp")
(setq annoscale "1-1/2\" = 1'-0\"")
(setvar "cannoscale" annoscale)
(command "pspace")
(command "mview" "lock" "ON" ViewP "")
(setq Block nil)
(princ)
)
;=======================================================
;SET VIEWPORT BASED ON WINDOW SELECTION (1-1/2" = 1'-0")
;=======================================================
(defun C:DomVIEWPORT_SetViewPortProfileByWindow ()
(setq CurLayOut (getvar 'ctab))
(command "pspace")
(princ "\n*** SETVIEWPORT: PROFILE BY WINDOW (1-1/2) ***")
(setq ViewP (entsel "\nSelect VIEWPORT to modify: "))
(setq ViewPEnt (entget (car ViewP)))
(setq ViewPID (cdr (assoc 69 ViewPEnt)))
(if Block
()
(progn
(setvar 'tilemode 1)
(initget 1)
(setq pt1 (getpoint "\n\t***\tPick lower left corner\t*** \n : "))
(initget 1)
(setq pt2 (getcorner pt1 "\n\t***\tPick upper right corner\t*** \n : "))
(setvar 'ctab CurLayOut)
);progn
);if
(command "mview" "lock" "off" ViewP "")
(command "mspace")
(setvar "cvport" ViewPID)
(command "zoom" "window" pt1 pt2)
(command "zoom" "scale" "1/8xp")
(setq annoscale "1-1/2\" = 1'-0\"")
(setvar "cannoscale" annoscale)
(command "pspace")
(command "mview" "lock" "ON" ViewP "")
(setq Block nil)
(princ)
)