I am slowly trying to get to grips with VB.NET, after a good few years of messing around with VBA.
I’m currently writing some code to try to improve CAD’s MEASURE command, but I’ve hit a bit of a stumbling block.
I have my command working to the extent that it will place blocks at regular intervals along a polyline, but I would like to add the generated blocks to a selection set, so you can use “previous” to select them like you can with CAD’s MEASURE command.

e.g. If I used the MEASURE command in CAD to place blocks along a polyline, then wanted to explode the blocks directly after, I could just use:
to explode the previous selection set, but my code never adds the blocks to a selection set – so you have to select them manually.

To add an entity to a selection set in VBA you would do something like this (excuse the pseudo-code):

Dim Ent as Entity
Ent = (whatever)

Dim SS as SelectionSet

VB.NET doesn’t seem to have an Add method for selection sets though, as far as I can gather you can only get them by using SelectAll & a dxf code filter – which would just grab all instances of the block, unless I went down the route of adding a temporary unique layer for them, or something along those lines.

Am I missing something obvious here?

Thanks in advance,