PDA

View Full Version : [SOLVED:] VBA Code Required



Hanumant
06-15-2016, 11:47 AM
In range G14 you have an example of the table I want.
' Note that the macro should work without any change in the VBA Code if there is more or less than 31 project and if there is
' more or less than 3 different benefits and complexity.
'
' You have to write below the VBA code to do this.

Results should appear like this.



Example of result of the macro


Benefit/Compexity
Easy
Medium
Difficult


High
Project_1 Project_15 Project_23
Project_2 Project_3 Project_11 Project_2 Project_3 Project_11
Project_5 Project_24 Project_29


Medium
Project_4 Project_9 Project_14 Project_19 Project_28
Project_16 Project_17 Project_16 Project_17
Project_6 Project_12 Project_13 Project_18 Project_21 Project_22 Project_31


Low
Project_7 Project_8 Project_10 Project_30
Project_20 Project_26 Project_27 Project_20 Project_26 Project_27
Project_25










Data:



Project Name
Benefit
Complexity


Project_1
High
Easy


Project_2
High
Medium


Project_3
High
Medium


Project_4
Medium
Easy


Project_5
High
Difficult


Project_6
Medium
Difficult


Project_7
Low
Easy


Project_8
Low
Easy


Project_9
Medium
Easy


Project_10
Low
Easy


Project_11
High
Medium


Project_12
Medium
Difficult


Project_13
Medium
Difficult


Project_14
Medium
Easy


Project_15
High
Easy


Project_16
Medium
Medium


Project_17
Medium
Medium


Project_18
Medium
Difficult


Project_19
Medium
Easy


Project_20
Low
Medium


Project_21
Medium
Difficult


Project_22
Medium
Difficult


Project_23
High
Easy


Project_24
High
Difficult


Project_25
Low
Difficult


Project_26
Low
Medium


Project_27
Low
Medium


Project_28
Medium
Easy


Project_29
High
Difficult


Project_30
Low
Easy


Project_31
Medium
Difficult:banghead:

JKwan
06-15-2016, 02:53 PM
give this a try

Hanumant
06-15-2016, 07:51 PM
Hi JKwan,

Thanks for the help.

It is working fine.