اذهب الي المحتوي
أوفيسنا

الردود الموصى بها

قام بنشر (معدل)

السلام عليكم ورحمة الله وبركاته

اخواني الأعضاء

هذا كود إيجاد إيرادات الربع الأول:

من تاريخ (text2) وحتى تاريخ (text4)

Me.Text2 = DateSerial(Year(Date), Int((Month(Date) - 1) / 3) * 0 + 1, 1)
Me.Text4 = DateSerial(Year(Date), Int((Month(Date) - 1) / 3) * 0 + 4, 0)
والمطلوب:

كود إيرادات الربع الثاني والثالث والأخير

أشكر الجميع على سعة الصدر

تم تعديل بواسطه أيمن عبادي
قام بنشر

الأخوة الكرام

لله الحمد تمكنت من إيجاد الحل ، وأضعه بين أيديكم للاستفادة منه

كود الربع الأول:

Me.Text2 = DateSerial(Year(Date), Int((Month(Date) - 1) / 3) * 0 + 1, 1)
Me.Text4 = DateSerial(Year(Date), Int((Month(Date) - 1) / 3) * 0 + 4, 0)

كود الربع الثاني:

Me.Text2 = DateSerial(Year(Date), Int((Month(Date) + 1) / 3) * 1 + 1, 1)
Me.Text4 = DateSerial(Year(Date), Int((Month(Date) + 1) / 3) * 1 + 4, 0)

كود الربع الثالث:

Me.Text2 = DateSerial(Year(Date), Int((Month(Date) + 1) / 3) * 2 + 1, 1)
Me.Text4 = DateSerial(Year(Date), Int((Month(Date) + 1) / 3) * 2 + 4, 0)

كود الربع الأخير:

Me.Text2 = DateSerial(Year(Date), Int((Month(Date) + 1) / 3) * 3 + 1, 1)
Me.Text4 = DateSerial(Year(Date), Int((Month(Date) + 1) / 3) * 3 + 4, 0)

  • Thanks 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

زائر
اضف رد علي هذا الموضوع....

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • تصفح هذا الموضوع مؤخراً   0 اعضاء متواجدين الان

    • لايوجد اعضاء مسجلون يتصفحون هذه الصفحه
×
×
  • اضف...

Important Information