1. 程式人生 > >【自用】 EXCEL 自己用到的一些公式

【自用】 EXCEL 自己用到的一些公式

上碼

'rem 根據C-ID輸出:1型別 & 2等級
=SWITCH(MID(C195,19,1),"4","肢","1","視","2","聽","3","Na","5","智","6","神","7","多","其")
=SWITCH(MID(C195,20,1),"1","一級","2","二級","3","三級","4","四級","其他")

'rem 根據ID輸出:1 Gens & 2出生年月日 & 3年齡(整)
=IF(MOD(MID(C195,17,1),2)=0,"女","男")
=DATE(MID(C195,7,4),MID(C195,11,2),MID(C195,13,2))
=YEAR(TODAY())-MID(C195,7,4)