diff options
author | Winfried Donkers <osc@dci-electronics.nl> | 2012-05-09 16:47:13 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2012-05-13 13:51:13 +0200 |
commit | 4e71be498903dee5bf719a73f4976bb5356335dd (patch) | |
tree | be542ccf54df83afe75f56ae341b11c66afedef9 /formula | |
parent | 2068144fdcfdee3abe2a90b3b4b3bd49589618f2 (diff) |
fdo#44456 added calc function DATEDIF as in ODF1.2
Change-Id: I082ea20d02bf37d515fc33d627281696fc48fcb6
Diffstat (limited to 'formula')
-rw-r--r-- | formula/inc/formula/compiler.hrc | 7 | ||||
-rw-r--r-- | formula/inc/formula/opcode.hxx | 1 | ||||
-rw-r--r-- | formula/source/core/resource/core_resource.src | 6 |
3 files changed, 11 insertions, 3 deletions
diff --git a/formula/inc/formula/compiler.hrc b/formula/inc/formula/compiler.hrc index 15d8aab91e3c..a2d4bb52f10f 100644 --- a/formula/inc/formula/compiler.hrc +++ b/formula/inc/formula/compiler.hrc @@ -399,10 +399,11 @@ #define SC_OPCODE_BITXOR 397 #define SC_OPCODE_BITRSHIFT 398 #define SC_OPCODE_BITLSHIFT 399 -#define SC_OPCODE_STOP_2_PAR 400 -#define SC_OPCODE_LAST_OPCODE_ID 399 /* last OpCode */ +#define SC_OPCODE_GET_DATEDIF 400 +#define SC_OPCODE_STOP_2_PAR 401 +#define SC_OPCODE_LAST_OPCODE_ID 401 /* last OpCode */ -/*** Interna ***/ +/*** Internal ***/ #define SC_OPCODE_INTERNAL_BEGIN 9999 #define SC_OPCODE_TTT 9999 #define SC_OPCODE_INTERNAL_END 9999 diff --git a/formula/inc/formula/opcode.hxx b/formula/inc/formula/opcode.hxx index b1e585cd8548..a1543ddcb427 100644 --- a/formula/inc/formula/opcode.hxx +++ b/formula/inc/formula/opcode.hxx @@ -212,6 +212,7 @@ enum OpCodeEnum ocGetTime = SC_OPCODE_GET_TIME, ocGetDiffDate = SC_OPCODE_GET_DIFF_DATE, ocGetDiffDate360 = SC_OPCODE_GET_DIFF_DATE_360, + ocGetDateDif = SC_OPCODE_GET_DATEDIF, ocMin = SC_OPCODE_MIN, ocMax = SC_OPCODE_MAX, ocSum = SC_OPCODE_SUM, diff --git a/formula/source/core/resource/core_resource.src b/formula/source/core/resource/core_resource.src index 12cb57d01bb8..12592316e384 100644 --- a/formula/source/core/resource/core_resource.src +++ b/formula/source/core/resource/core_resource.src @@ -170,6 +170,7 @@ Resource RID_STRLIST_FUNCTION_NAMES_ENGLISH_ODFF String SC_OPCODE_GET_TIME { Text = "TIME" ; }; String SC_OPCODE_GET_DIFF_DATE { Text = "DAYS" ; }; String SC_OPCODE_GET_DIFF_DATE_360 { Text = "DAYS360" ; }; + String SC_OPCODE_GET_DATEDIF { Text = "DATEDIF" ; }; String SC_OPCODE_MIN { Text = "MIN" ; }; String SC_OPCODE_MIN_A { Text = "MINA" ; }; String SC_OPCODE_MAX { Text = "MAX" ; }; @@ -502,6 +503,7 @@ Resource RID_STRLIST_FUNCTION_NAMES_ENGLISH String SC_OPCODE_GET_TIME { Text = "TIME" ; }; String SC_OPCODE_GET_DIFF_DATE { Text = "DAYS" ; }; String SC_OPCODE_GET_DIFF_DATE_360 { Text = "DAYS360" ; }; + String SC_OPCODE_GET_DATEDIF { Text = "DATEDIF" ; }; String SC_OPCODE_MIN { Text = "MIN" ; }; String SC_OPCODE_MIN_A { Text = "MINA" ; }; String SC_OPCODE_MAX { Text = "MAX" ; }; @@ -1175,6 +1177,10 @@ Resource RID_STRLIST_FUNCTION_NAMES { Text [ en-US ] = "DAYS360" ; }; + String SC_OPCODE_GET_DATEDIF + { + Text [ en-US ] = "DATEDIF" ; + }; String SC_OPCODE_MIN { Text [ en-US ] = "MIN" ; |