+ Reply to Thread
Results 1 to 3 of 3

Thread: Ungroup

  1. #1

    Ungroup

    I’d like to select all groups (or everything) and ungroup all groups at all levels. Here is what I’m trying:
    objects = rs.AllObjects(True)
    ifobject: rs.RemoveObjectFromAllGroups(object)
    Here is my error:
    Message: Parameter must be a Guid or stringrepresenting a Guid
    How do I get the GUID of all the objects so that I can pass the ID’sk on to RemoveObjectsFromAllGroups?

    Thanks
    Brad

  2. #2
    Senior Member Steve Baer's Avatar
    Join Date
    Apr 2010
    Location
    Seattle
    Posts
    1,464
    Blog Entries
    19
    Hi Brad,
    objects is a list of ids, you need to iterate through that list and call RemoveObjectFromAllGroups on each item

    Python Code:
      objects = rs.AllObjects()
      if objects:
          for obj in objects: rs.RemoveObjectFromAllGroups(obj)

  3. #3
    Perfect! Thanks Steve!!

+ Reply to Thread

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts