Specifies the size of the object selection target.
Supported platforms: Windows only
VBA:
object.PickBoxSize
Type: PreferencesSelection
The object this property applies to.
Read-only: No
Type: Long
The height of the object selection target in pixels. You can enter a value from 0 to 50.
The initial value of this property is 3.
VBA:
Sub Example_PickBoxSize()
' This example reads and modifies the preference value that controls
' the size of the object selection target.
' When finished, this example resets the preference value back to
' its original value.
Dim ACADPref As AcadPreferencesSelection
Dim originalValue As Variant, newValue As Variant
' Get the selection preferences object
Set ACADPref = ThisDrawing.Application.Preferences.Selection
' Read and display the original value
originalValue = ACADPref.PickBoxSize
MsgBox "The PickBoxSize preference is set to: " & originalValue
' Modify the PickBoxSize preference by setting it to 5
ACADPref.PickBoxSize = 5
newValue = ACADPref.PickBoxSize
MsgBox "The PickBoxSize preference has been set to: " & newValue
' Reset the preference back to its original value
'
' * Note: Comment out this last section to leave the change to
' this preference in effect
ACADPref.PickBoxSize = originalValue
MsgBox "The PickBoxSize preference was reset back to: " & originalValue
End Sub
Visual LISP:
(vl-load-com)
(defun c:Example_PickBoxSize()
;; This example reads and modifies the preference value that controls
;; the size of the object selection target.
;; When finished, this example resets the preference value back to
;; its original value.
(setq acadObj (vlax-get-acad-object))
(setq preferences (vla-get-Preferences acadObj))
;; Read and display the original value
(setq originalValue (vla-get-PickBoxSize (vla-get-Selection preferences)))
(alert (strcat "The PickBoxSize preference is set to: " (itoa originalValue)))
;; Modify the PickBoxSize preference by setting it to 5
(vla-put-PickBoxSize (vla-get-Selection preferences) 5)
(setq newValue (vla-get-PickBoxSize (vla-get-Selection preferences)))
(alert (strcat "The PickBoxSize preference has been set to: " (itoa newValue)))
;; Reset the preference back to its original value
;;
;; * Note: Comment out this last section to leave the change to
;; this preference in effect
(vla-put-PickBoxSize (vla-get-Selection preferences) originalValue)
(alert (strcat "The PickBoxSize preference was reset back to: " (itoa originalValue)))
)