Hi everyone,
I need VBA code to filter, text2column, copy and paste processed data in a new sheet.
I need to return text in Question 1, question 2,... columns into number, then filter rows which in Group column is "ABC", and copy - paste these processed data in a new sheet. New sheet will include column Group, Role, Question 1, 2, 3,... (after split text). I also need a textbox to ask which group I want to filter.
My sample data is as below:
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD]Group[/TD]
[TD]Role[/TD]
[TD]Question 1[/TD]
[TD]Open question 1[/TD]
[TD]Question 2[/TD]
[TD]Open question 2[/TD]
[TD]Question 3[/TD]
[TD]Open question 3[/TD]
[/TR]
[TR]
[TD][TABLE="width: 64"]
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]ABC[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]1[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]XYZ[/TD]
[TD]2[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]3[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]1[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]GHI[/TD]
[TD]1[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]2[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]XYI[/TD]
[TD]3[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]HIQ[/TD]
[TD]3[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]3[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[/TR]
</tbody>[/TABLE]
Please help me. Thank you!
I need VBA code to filter, text2column, copy and paste processed data in a new sheet.
I need to return text in Question 1, question 2,... columns into number, then filter rows which in Group column is "ABC", and copy - paste these processed data in a new sheet. New sheet will include column Group, Role, Question 1, 2, 3,... (after split text). I also need a textbox to ask which group I want to filter.
My sample data is as below:
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD]Group[/TD]
[TD]Role[/TD]
[TD]Question 1[/TD]
[TD]Open question 1[/TD]
[TD]Question 2[/TD]
[TD]Open question 2[/TD]
[TD]Question 3[/TD]
[TD]Open question 3[/TD]
[/TR]
[TR]
[TD][TABLE="width: 64"]
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]ABC[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD]1[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]XYZ[/TD]
[TD]2[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]3[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]1[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]GHI[/TD]
[TD]1[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]2[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]XYI[/TD]
[TD]3[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]HIQ[/TD]
[TD]3[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[/TR]
[TR]
[TD]ABC[/TD]
[TD]3[/TD]
[TD]4 - Satisfied[/TD]
[TD]NA[/TD]
[TD]3 - Neutral[/TD]
[TD]NA[/TD]
[TD]5 - Very satisfied[/TD]
[TD]NA[/TD]
[/TR]
</tbody>[/TABLE]
Please help me. Thank you!