So, I have a list of Yes/No questions and what I am trying to do is create a string of the terms that have a Y beside them. For example in the data below, I would like the cell to return Agitated, Angry, Depressed and I will reference that in a different part of a sheet. I would like for this to be dynamic, so if I put a 'Y' beside Apathetic, the string would read Agitated, Angry, Apathetic, and Depressed. I hope that makes sense. Here is the data:
[TABLE="width: 185"]
<tbody>[TR]
[TD]Mood:[/TD]
[TD]Yes/No[/TD]
[/TR]
[TR]
[TD]Agitated[/TD]
[TD]Y[/TD]
[/TR]
[TR]
[TD]Angry[/TD]
[TD]Y[/TD]
[/TR]
[TR]
[TD]Anxious[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Apathetic[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Depressed[/TD]
[TD]Y[/TD]
[/TR]
[TR]
[TD]Dysthymic[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Elevated[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Emotional[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Fearful[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Manic[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Withdrawn[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Other:[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 185"]
<tbody>[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
I know I could do this with a bunch of If statements stacked together, but I would love to exclude or skip the items that are blank.
Thanks in advance!!!
[TABLE="width: 185"]
<tbody>[TR]
[TD]Mood:[/TD]
[TD]Yes/No[/TD]
[/TR]
[TR]
[TD]Agitated[/TD]
[TD]Y[/TD]
[/TR]
[TR]
[TD]Angry[/TD]
[TD]Y[/TD]
[/TR]
[TR]
[TD]Anxious[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Apathetic[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Depressed[/TD]
[TD]Y[/TD]
[/TR]
[TR]
[TD]Dysthymic[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Elevated[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Emotional[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Fearful[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Manic[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Withdrawn[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Other:[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 185"]
<tbody>[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
I know I could do this with a bunch of If statements stacked together, but I would love to exclude or skip the items that are blank.
Thanks in advance!!!