Selection Count

Discussion in 'AutoCAD' started by Ledi, Jan 10, 2005.

  1. Ledi

    Ledi Guest

    Hi!

    I'm using 2005 and i have a small problem.

    Private Sub AcadDocument_SelectionChanged()
    MsgBox "Count: " & ThisDrawing.ActiveSelectionSet.Count
    End Sub

    if i select object it counts 1, if I press ESC so that no object is selected it still counts 1. Is there a way to clear this so i can distinct when objects are selected and when there is no obj. selected?
     
    Ledi, Jan 10, 2005
    #1
  2. hi,

    try instead of 'ActiveSelectionSet' the 'PickFirstSelectionSet', the pickfirstselection is what the user see as gripped, the activeselectionset may
    be any other selection set.

    - alfred -
     
    Alfred NESWADBA, Jan 11, 2005
    #2
  3. Ledi

    Ledi Guest

    yes, this is exactly what i need, thanks
     
    Ledi, Jan 11, 2005
    #3
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.