使用带有标题的VBA转置数据

时间:2018-07-26 05:19:14

标签: vba transpose

我在Excel中具有以下数据。我需要将数据与Months调换

Name    PROJECT Task    43101   43102   43103   43104   43105
Emp 1   Project A   SA  8   8   8   8   8
Emp 1   Project A   BA  8   8   8   8   8
Emp 2   Project A   DM  8   8   8   8   8
Emp 3   Project A   SE  8   8   8   8   8
Emp 4   Project A   SE  8   8   8   8   8
Emp 5   Holiday QA  

我需要按如下所示对输出进行转换。请求一些人来解决这个问题。

Name    PROJECT Task    Date    Hours
Emp 1   Project A   SA  1/1/2018    8
Emp 1   Project A   BA  1/1/2018    8
Emp 2   Project A   DM  1/1/2018    8
Emp 3   Project A   SE  1/1/2018    8
Emp 4   Project A   SE  1/1/2018    8
Emp 5   Holiday QA  1/1/2018    
Emp 1   Project A   SA  1/2/2018    8
Emp 1   Project A   BA  1/2/2018    8
Emp 2   Project A   DM  1/2/2018    8
Emp 3   Project A   SE  1/2/2018    8
Emp 4   Project A   SE  1/2/2018    8
Emp 5   Holiday QA  1/2/2018    
Emp 1   Project A   SA  1/3/2018    8
Emp 1   Project A   BA  1/3/2018    8
Emp 2   Project A   DM  1/3/2018    8
Emp 3   Project A   SE  1/3/2018    8
Emp 4   Project A   SE  1/3/2018    8
Emp 5   Holiday QA  1/3/2018    
Emp 1   Project A   SA  1/4/2018    8
Emp 1   Project A   BA  1/4/2018    8
Emp 2   Project A   DM  1/4/2018    8
Emp 3   Project A   SE  1/4/2018    8
Emp 4   Project A   SE  1/4/2018    8
Emp 5   Holiday QA  1/4/2018    
Emp 1   Project A   SA  1/5/2018    8
Emp 1   Project A   BA  1/5/2018    8
Emp 2   Project A   DM  1/5/2018    8
Emp 3   Project A   SE  1/5/2018    8
Emp 4   Project A   SE  1/5/2018    8
Emp 5   Holiday QA  1/5/2018    

0 个答案:

没有答案