function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
teratera 

和暦表示

通常の日付項目を、別項目で和暦で表示したいです。

可能でしょうか?

ご教授ください。

fukumimifukumimi

if(
and(XXXX >=date(1868,09,08),XXXX <=date(1912,07,29)),
"明治"&text(year(XXXX)-1867)&"年"&text(month(XXXX))&" 月"&
text(day(XXXX))&"日",
if(
and(XXXX >=date(1912,07,30),XXXX <=date(1926,12,24)),
"大正"&text(year(XXXX)-1911)&"年"&text(month(XXXX))&" 月"&
text(day(XXXX))&"日",
if(
and(XXXX >=date(1926,12,25),XXXX <=date(1989,01,07)),
"昭和"&text(year(XXXX)-1925)&"年"&text(month(XXXX))&" 月"&
text(day(XXXX))&"日",
if(
XXXX >=date(1989,01,08),
"平成"&text(year(XXXX)-1988)&"年"&text(month(XXXX))&" 月"&
text(day(XXXX))&"日","#エラー")))) 
----------------------------------------------------
明治:1868/09/08~1912/07/29
大正:1912/07/30~1926/12/24
昭和:1926/12/25~1989/01/07
平成:1989/01/08~

ってな感じです