以上功能需要用公式或者VBA实现,不要说到Word里面粘贴替换段落标记为逗号,因为这个表格需要今后实时更新,谢谢!作者: pureshadow 时间: 2014-7-2 17:57
dim MyRow as long, i as long
dim MyStr as string
for myrow = 2 to cells(rows.count,1).end(xlup).row
if cells(myrow,1)= cells(myrow+1,1) then
mystr = mystr & "," & cells(myrow,3)
else
i = i +1
cells(i,6)=cells(myrow,1)
cells(i,7)= mid(mystr & "," & cells(myrow,3),2,9999)
mystr = ""
end if
next作者: sugonhr3 时间: 2014-7-3 13:43
谢谢楼上,为了方便大家理解,我这里有一个说明。作者: roych 时间: 2014-7-7 14:44
详见“人员编制信息表.xlsm”文件。
按顺序先后运行getData()和getFormat()即可。作者: sugonhr3 时间: 2014-7-12 09:14
问题已经解决,感谢楼上的帮助!!!