is there anyway to control “Expand All” and “CollapseAll” before calling GetLayer?
No, sorry. This form is meant to mirror the layout displayed in the Layers panel.
You should be able to iterate through layers and collapse/expand them before running this method but as Dale said it would affect your layer panel as well as these two correspond.
i’m not too concerned about effecting the layers panel, i just want a more condensed view in the GetLayer window. it can get pretty unruly.