1. I don't think you should use IComponent2 in a VBA macro. Use Component2:
Dim SwComp As Component2
2. Check that Bodies is non-empty:
If IsEmpty(Bodies) then 'display some message to the user and quit
How do I tell it to just go to the next component if Bodies is empty?
Everytime I try to tell it to GoTo a line I get a "label not defined" error.
How are you labelling the line to go to?
A label is a name followed by a colon. For example:
Notice that the goto does not end in a colon
I didn't save it because I couldn't get it to work, but it was something like this
If IsEmpty(Bodies) Then
GoTo LN200 '(for example)
Else GoTo LN199
But how did you label those lines?
You can't goto a particular line number. You must place a label there.
I understand now. Yeah, I was just putting GoTo LN200
Thank you. I'll give that a go.