انتقل إلى المحتوى الرئيسي

كيف تحسب مدة الخدمة من تاريخ الاستئجار في إكسيل؟

إذا كان لديك نطاق من البيانات بما في ذلك أسماء الموظفين وتاريخ انضمامهم لشركتك في ورقة عمل ، فقد ترغب الآن في حساب مدة خدمتهم ، فهذا يعني معرفة عدد السنوات والأشهر التي عمل فيها الموظف في شركتك. في هذه المقالة سأتحدث عن طريقة سريعة لحل هذه الوظيفة لك.

احسب مدة الخدمة من تاريخ الاستئجار باستخدام دالة YEARFRAC

احسب مدة الخدمة من تاريخ الاستئجار باستخدام وظيفة DATEDIF

احسب مدة الخدمة من تاريخ الاستئجار إلى اليوم باستخدام وظيفة DATEDIF

احسب مدة الخدمة من تاريخ الاستئجار بميزة مذهلة


احسب مدة الخدمة من تاريخ الاستئجار باستخدام دالة YEARFRAC

لحساب طول الخدمة من تاريخ الاستئجار وتاريخ محدد ، يمكن أن تساعدك وظيفة YEARFRAC.

الرجاء إدخال الصيغة التالية أو نسخها في خلية فارغة:

=INT(YEARFRAC(B2,C2))

ملاحظات: في الصيغة أعلاه ، B2 هي خلية تاريخ الاستئجار و C2 هي خلية تاريخ الانتهاء.

ثم اسحب مقبض التعبئة لنسخ fromula إلى الخلايا الأخرى التي تحتاجها ، وستحصل على مدة خدمة الشخص في سنوات.


احسب مدة الخدمة من تاريخ الاستئجار باستخدام وظيفة DATEDIF

إذا كنت بحاجة إلى حساب طول الخدمة في السنوات والأشهر والأيام المحددة ، يمكن أن تقدم لك وظيفة DATEDIF في Excel خدمة.

احسب مدة الخدمة بالسنوات:

الرجاء إدخال الصيغة التالية أو نسخها في خلية فارغة:

=DATEDIF(B2, C2, "y")& " Years"


احسب مدة الخدمة بالسنوات والشهور:

الرجاء تطبيق الصيغة التالية:

=DATEDIF(B2,C2,"y")&" Years, "&DATEDIF(B2,C2,"ym")&" Months"


احسب مدة الخدمة بالسنوات والشهور والأيام:

قم بتطبيق الصيغة التالية:

=DATEDIF(B2,C2,"y") & " Years, " & DATEDIF(B2,C2,"ym") & " Months, " & DATEDIF(B2,C2,"md") & " Days"

ملاحظات: في الصيغة أعلاه ، B2 هي خلية تاريخ الاستئجار و C2 هي خلية تاريخ الانتهاء.


احسب مدة الخدمة من تاريخ الاستئجار إلى اليوم باستخدام وظيفة DATEDIF

بعض السمات ، قد ترغب في حساب طول الخدمة من تاريخ الاستئجار إلى اليوم ، لذلك ، كل يوم تفتح فيه ورقة العمل ، سيتم تحديث طول الخدمة تلقائيًا. في هذه الحالة ، يجب عليك دمج وظيفة TODAY في وظيفة DATEDIF.

يرجى تطبيق أي من الصيغ أدناه حسب حاجتك:

=DATEDIF(B4, TODAY(), "y")& " Years"
= DATEDIF (B4، TODAY ()، "y") & "Years،" & DATEDIF (B4، TODAY ()، "ym") & "Months"
= DATEDIF (B6، TODAY ()، "y") & "Years،" & DATEDIF (B4، TODAY ()، "ym") & "Months،" & DATEDIF (B4، TODAY ()، "md") & "أيام"


احسب مدة الخدمة من تاريخ الاستئجار بميزة مذهلة

من الصعب نوعًا ما عليك أن تتذكر الكثير من الصيغ ، ولكن إذا كان لديك كوتولس ل إكسيل، بما لديها مساعد التاريخ والوقت يمكنك حساب مدة الخدمة بسرعة في السنوات أو الأشهر أو الأيام أو السنوات + الأشهر + الأيام أو التنسيقات الأخرى حسب حاجتك.

ملحوظة:لتطبيق هذا مساعد التاريخ والوقتأولاً ، يجب عليك تنزيل ملف كوتولس ل إكسيل، ثم قم بتطبيق الميزة بسرعة وسهولة.

بعد تثبيت كوتولس ل إكسيل، يرجى القيام بذلك على النحو التالي:

1. انقر فوق الخلية التي تريد تحديد موقع النتيجة فيها ، ثم انقر فوقها كوتولسمساعد الصيغة > مساعد التاريخ والوقت، انظر لقطة الشاشة:

2. في مساعد التاريخ والوقت في مربع الحوار ، قم بالعمليات التالية:

  • تحقق فرق الخيار من النوع قسم.
  • في مجلة مدخلات الحجج مربعات النص ، حدد الخلايا التي تحتوي على تاريخ الاستئجار وتاريخ الانتهاء بشكل منفصل ؛
  • ثم اختر نوع نتيجة الإخراج حسب حاجتك. على سبيل المثال ، يمكنك الحصول على مدة الخدمة بالسنوات والشهور والسنوات + الأشهر + الأيام والسنوات + الأشهر وما إلى ذلك.

3. بعد الانتهاء من الإعدادات ، انقر فوق OK ، وستحصل على أول نتيجة محسوبة ، إذن ، ما عليك سوى سحب مقبض التعبئة لملء هذه الصيغة لاختبار الخلايا ، والآن ستحصل على النتيجة التالية حسب حاجتك:

انقر لتنزيل Kutools for Excel والتجربة المجانية الآن!


المزيد من المقالات ذات الصلة:

  • عد عدد الأيام / أيام العمل / عطلات نهاية الأسبوع بين تاريخين
  • هل سبق لك أن احتجت إلى حساب عدد الأيام بين تاريخين في Excel؟ في بعض الأحيان ، قد ترغب فقط في حساب أيام العمل بين تاريخين ، وفي وقت ما ، تحتاج إلى حساب أيام نهاية الأسبوع فقط بين التاريخين. كيف يمكنك حساب عدد الأيام بين تاريخين في حالة معينة؟
  • حساب الأيام والساعات والدقائق بين تاريخين
  • لنفترض أن لديك عمودين من خلايا التاريخ والوقت ، والآن ، تريد حساب الفرق في الأيام والساعات والدقائق بين خليتي التاريخ والوقت كما هو موضح في لقطة الشاشة التالية. في هذا المقال سأتحدث عن بعض الطرق لحل هذه المهمة من أجلك.

أفضل أدوات إنتاجية المكتب

🤖 مساعد Kutools AI: إحداث ثورة في تحليل البيانات على أساس: التنفيذ الذكي   |  إنشاء التعليمات البرمجية  |  إنشاء صيغ مخصصة  |  تحليل البيانات وإنشاء الرسوم البيانية  |  استدعاء وظائف Kutools...
الميزات الشعبية: البحث عن التكرارات أو تمييزها أو تحديدها   |  حذف الصفوف الفارغة   |  دمج الأعمدة أو الخلايا دون فقدان البيانات   |   جولة بدون صيغة 
سوبر بحث: معايير متعددة VLookup    VLookup ذات القيمة المتعددة  |   VLookup عبر أوراق متعددة   |   بحث غامض ....
قائمة منسدلة متقدمة: إنشاء القائمة المنسدلة بسرعة   |  القائمة المنسدلة التابعة   |  قائمة منسدلة متعددة التحديد ....
مدير العمود: إضافة عدد محدد من الأعمدة  |  نقل الأعمدة  |  تبديل حالة رؤية الأعمدة المخفية  |  مقارنة النطاقات والأعمدة 
الميزات المميزة: التركيز على الشبكة   |  عرض تصميم   |   شريط الفورمولا الكبير    مدير المصنفات والأوراق   |  مكتبة الموارد (النص السيارات)   |  منتقي التاريخ   |  اجمع أوراق العمل   |  تشفير/فك تشفير الخلايا    إرسال رسائل البريد الإلكتروني عن طريق القائمة   |  سوبر تصفية   |   مرشح خاص (تصفية غامق / مائل / يتوسطه خط ...) ...
أفضل 15 مجموعة أدوات12 نص الأدوات (إضافة نص, إزالة الأحرف، ...)   |   +50 رسم الأنواع (مخطط جانت، ...)   |   40+ عملي الصيغ (احسب العمر على أساس تاريخ الميلاد، ...)   |   19 إدخال الأدوات (أدخل رمز الاستجابة السريعة, إدراج صورة من المسار، ...)   |   12 تحويل الأدوات (أرقام إلى كلمات, نتيجة تحويل عملة، ...)   |   7 دمج وتقسيم الأدوات (الجمع بين الصفوف المتقدمة, تقسيم الخلايا، ...)   |   ... و اكثر

عزز مهاراتك في Excel باستخدام Kutools for Excel، واختبر كفاءة لم يسبق لها مثيل. يقدم Kutools for Excel أكثر من 300 ميزة متقدمة لتعزيز الإنتاجية وتوفير الوقت.  انقر هنا للحصول على الميزة التي تحتاجها أكثر...

الوصف


يجلب Office Tab الواجهة المبوبة إلى Office ، ويجعل عملك أسهل بكثير

  • تمكين التحرير والقراءة المبوبة في Word و Excel و PowerPointوالناشر والوصول و Visio والمشروع.
  • فتح وإنشاء مستندات متعددة في علامات تبويب جديدة من نفس النافذة ، بدلاً من النوافذ الجديدة.
  • يزيد من إنتاجيتك بنسبة 50٪ ، ويقلل مئات النقرات بالماوس كل يوم!
Comments (20)
Rated 5 out of 5 · 1 ratings
This comment was minimized by the moderator on the site
First, thank you very much for helping us!

I am trying to use the formula for years and months of service (=DATEDIF(B2,C2,"y")&" Years, "&DATEDIF(B2,C2,"ym")&" Months") which works great, but I would like to add that line and another line that just has numbers in it. Is that possible? For instance: The formula =DATEDIF(B2,C2,"y")&" Years, "&DATEDIF(B2,C2,"ym")&" Months" is located in D2 and I would like to add number of years and months of service from another agency in E2 with the total sum in F2.

All assistance is great appreciated.
Rated 5 out of 5
This comment was minimized by the moderator on the site
If I have a mixed list of employees still with the company (with start date only) and employees no longer with the company (with start and end date), is there a formula for calculating length of service using current date unless there is an end date, in which case the end date would be used in place of the current date to calculate total length of service from start to end?
This comment was minimized by the moderator on the site
what version of Excel can i get this? I am unable to get the function on Excel 2016
This comment was minimized by the moderator on the site
Hello,
The Excel version in the example is Excel 2010. The DATEDIF function is not available in Excel 2013 and later versions.
DATEDIF is not a standard function and hence not part of functions library and so no documentation. Microsoft doesn't promote to use this function as it gives incorrect results in few circumstances.

This function does not appear in the 'Insert Function' dialog box and is not recognised in the 'Function Arguments' dialog box.
The accuracy of this function was improved slightly in Excel 2010 but some of the bugs were never fixed.

Hope it helps. Have a nice day.
Sincerely,
Mandy
This comment was minimized by the moderator on the site
After the years of service has been determined. How do you calculate the persons service computation date (SCD). Is there a formula to subtract the years of service from the persons new appointment date to get their SCD leave date?
This comment was minimized by the moderator on the site
i m in problem; I am new joining to Govt. dept. as Junior Clerk in Accounts site: I want to calculate to make service end period, and after to add extra months years days in service period given by government relaxation period to complete service 9 to 10 years as (the total service is 8 year, 8 months, 18 days) but govt. give 10 months and 28 days to compile the service period for allowing the come in to as pensioner. Thanks to you for solve that problem.
This comment was minimized by the moderator on the site
Dear have a good health to you. I requesting for adjust more months days year in less service length 9 years to make complet 10 years. please tell about it.
This comment was minimized by the moderator on the site
How can I just highlight the cells if the yearly anniversary is within a week? For example They started on 01/10/2020 and I want the start date to be highlighted yellow if the date is 24/09 in each year and then turn red if the anniversary has passed, so turn red 7 days after the 1st?
This comment was minimized by the moderator on the site
Work Services Calculation 1 month different in formula
This comment was minimized by the moderator on the site
If service is 25 Year 07 Months 05 Days than i calculate no. of year and the result is 25, but need to calculate/consider full year if months is equal to 06 months or exceed. After calculation
This comment was minimized by the moderator on the site
For calculating the length of services in years, months and days with start date and end date, I noted that the result for James is 20 days. I would like to confirm if the end date means separation effective date (Day 1 after termination/separation) or last employment date.
Both start (hire date) and end date (last employment date "LED") should be inclusive in the calculation. It is expected to return 21 days but not 20 days as it counted no. of days from 12/11/2025 to 12/31/2025.
How to change the formula? Or should it be used termination effective date (LED + 1 day) as cell C2, instead of input "LED" as end date?
This comment was minimized by the moderator on the site
Florence, you are correct, and the tutorial above is simply wrong. When calculating years of service/length of service, the calculation must be inclusive of the last day worked. Using basic date subtraction formulas tell the *difference* between 2 dates (which will short the length of service by 1 day). For example, if someone stated the 1st, and ended the following day (2nd), taking the date difference would be 1 day (when they actually worked 2 days). Another example: If you use the method above for someone who started work on January 1st, and their last day was December 31st, it will not show that they've worked a complete year -- which is of course an error. The way to get the correct answer is to add +1 to the end date. So, everywhere you see C2 above should be C2+1. This is a significant problem where people everywhere are using this incorrect formula for calculating years of service. The formula is typically correct except the edge case of the last day of employment being the exact day before their start day. I'm in a dispute with my former employer over this very issue. Formulas like this should always be checked for edge cases like worked 1 day, 2 days, worked exactly 1 year, the anniversary date, day before/after, etc. When doing this, you will see all sorts of problems like the one you described.
This comment was minimized by the moderator on the site
Hi, Florence,If you want to include both the start date and end date when calculating, you just need add 1 after the days part as below formula:=DATEDIF(B2,C2,"y") & " Years, " & DATEDIF(B2,C2,"ym") & " Months, " & DATEDIF(B2,C2,"md")+1 & " Days"
Please try, hope it can help you!
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations