اذهب الي المحتوي
أوفيسنا
بحث مخصص من جوجل فى أوفيسنا
Custom Search

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

قام بنشر

الأساتذة الأفاضل

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

مرفق ملف للمشكلة التى تواجهنى مع النسبة 55 فقط...!!!

قمت بإنشاء استعلام جدولى لعمل حزم أو مجموعات النسب المئوية لاختبار ما، كل الأرقام تظهر صحيحة ما عدا المجموعة الخاصة ما بين 50 الى 55، يظهر عدد الممتحنين الحاصلين على 50% فقط ولايقوم بعد الحاصلين على 55%، حيث يقوم بعدهم مع اخر مجموعة فى الاستعلام.

أرجو الإفادة لحل هذه المشكلة، ولكم جزيل الشكر والتقدير

 

 

 

Problem 55-2003.rar

قام بنشر

وعليكم السلام 🙂

 

اذا كان في حقل الاستعلام شروط كثيرة ، فأنا الجأ الى الوحدة النمطية لتسهيل الامر ، وهذا ما فعلته هنا 🙂

1022.Clipboard01.jpg.c7fff2a53bb99e00637513e8d6f8d430.jpg

.

والنتيجة

1022.Clipboard02.jpg.8a48f0a4e93f203ab63a284d6f7c25b2.jpg

.

والوحدة النمطية:

Option Compare Database
Option Explicit

Public Function Per(Deg As String) As String


'Expr1: IIf([Deg1]="غـ","متخلف",IIf(((Val([Deg1])/20)*100)<50,"Less50",IIf(((Val([Deg1])/20)*100) Between 50 And 55,"50-55%",IIf(((Val([Deg1])/20)*100) Between 55.1 And 60,"55-60%",IIf(((Val([Deg1])/20)*100) Between 60.1 And 65,"60-65%",IIf(((Val([Deg1])/20)*100) Between 65.1 And 70,"65-70%",IIf(((Val([Deg1])/20)*100) Between 70.1 And 75,"70-75%",IIf(((Val([Deg1])/20)*100) Between 75.1 And 80,"75-80%",IIf(((Val([Deg1])/20)*100) Between 80.1 And 85,"80-85%",IIf(((Val([Deg1])/20)*100) Between 85.1 And 90,"85-90%",IIf(((Val([Deg1])/20)*100) Between 90.1 And 95,"90-95%",IIf(((Val([Deg1])/20)*100) Between 95.1 And 99.99,"95-99%","100%"))))))))))))

    Dim Grade As Double
    
    Grade = ((Val(Deg) / 20) * 100)
    
    If Deg = "غـ" Then
        Per = "متخلف"
    
    ElseIf Grade < 50 Then
        Per = "Less50"
    
    ElseIf Grade >= 50 And Grade <= 55 Then
        Per = "50-55%"
    
    ElseIf Grade >= 55.1 And Grade <= 60 Then
        Per = "55-60%"
    
    ElseIf Grade >= 60.1 And Grade <= 65 Then
        Per = "60-65%"
    
    ElseIf Grade >= 65.1 And Grade <= 70 Then
        Per = "65-70%"
    
    ElseIf Grade >= 70.1 And Grade <= 75 Then
        Per = "70-75%"
    
    ElseIf Grade >= 75.1 And Grade <= 80 Then
        Per = "75-80%"
    
    ElseIf Grade >= 80.1 And Grade <= 85 Then
        Per = "80-85%"
    
    ElseIf Grade >= 85.1 And Grade <= 90 Then
        Per = "85-90%"
    
    ElseIf Grade >= 90.1 And Grade <= 95 Then
        Per = "90-95%"
    
    ElseIf Grade >= 95.1 And Grade <= 99.99 Then
        Per = "95-99%"
    
    Else
        Per = "100%"
    
    End If
    
End Function

 

جعفر

1022.Problem 55-2003.mdb.zip

  • Like 3
قام بنشر

الله ينور عليك استاذى الكبير

تسلم الايادى يا رب

هل يمكن استبدال الوحده النمطية بقيم فى جدول 

لكى يكون الدرجات سهل تغييرها

ارجوا او اكون قد وفقت فى الشرح

قام بنشر

حيالله اخوي ابو الآء 🙂

 

هممم ، اذا قصدك تعمل جدول خاص للارقام ، وتكتب فيه الارقام 

1

1.1

1.2

1.3

1.4

1.5

1.6

1.7

1.8

1.9

2

2.1

...

100

وفي حقل آخر في الجدول تكتب النسبة لكل رقم ،

ثم في استعلام تربط حقل رقم هذا الجدول بمعدل الطالب في الجدول الآخر ، ثم تعطيه على هذا الاساس النسبة ،

فنعم ممكن 🙂

 

جعفر

  • Like 1
قام بنشر

الله ينور عليك استاذى الكبير

 

ان شاء الله سوف اقوم بعمل مثال مصغر 

وارفاقه فى مشاركه جديده

 

 

قام بنشر

جزاك الله خيرا.... جارى التجربة 

وللعلم، الدرجة تختلف من مادة لاخرى فبعض المواد من ٢٠ وبعضها من ١٠ واخرى من ٣٠، فهل يمكن أن تتضمن الدالة المنشأة هذه الحالات..؟

قام بنشر

تمام، جزاكم الله خيرًا على المجهود والمساعدة

قمت بعمل أكثر من دالة فى نفس الموديول لجميع الحالات التى أحتاجها مع تغيير اسم الدالة 

قام بنشر
10 ساعات مضت, N_ELMASRY said:

تمام، جزاكم الله خيرًا على المجهود والمساعدة

قمت بعمل أكثر من دالة فى نفس الموديول لجميع الحالات التى أحتاجها مع تغيير اسم الدالة 

هنا تكمن الفكره التى كنت اتحدث عنها

لما لا تكون هذه القيم فى جدول 

ويسهل تغييرها

ويمكن ايضا للمستخدم العادى تغييرها

والكود بأخذ هذه القيم من الجدول !!

  • 5 weeks later...
قام بنشر

السلام عليكم 🙂

 

في ٩‏/٣‏/٢٠١٩ at 08:10, N_ELMASRY said:

وللعلم، الدرجة تختلف من مادة لاخرى فبعض المواد من ٢٠ وبعضها من ١٠ واخرى من ٣٠، فهل يمكن أن تتضمن الدالة المنشأة هذه الحالات..؟

 

نعم ممكن 🙂

 

هذا الجدول الجديد، مثلا:

1022.Clipboard05.jpg.52feeae1852a945a7691dc6e46a3e12d.jpg

 

تم تعديل الاستعلام والوحدة النمطية لتتضمن جميع الدرجات:

1022.Clipboard03.jpg.2ab2907b2f238deec3b74420b75d843f.jpg

والنتيجة:

1022.Clipboard04.jpg.7bb9c1fd88fa249ac0caaccda6a19f58.jpg

 

 

وهذه الوحدة النمطية المعدلة:

Public Function Per(Deg As String, Final_Grade As Integer) As String


'Expr1: IIf([Deg1]="غـ","متخلف",IIf(((Val([Deg1])/20)*100)<50,"Less50",IIf(((Val([Deg1])/20)*100) Between 50 And 55,"50-55%",IIf(((Val([Deg1])/20)*100) Between 55.1 And 60,"55-60%",IIf(((Val([Deg1])/20)*100) Between 60.1 And 65,"60-65%",IIf(((Val([Deg1])/20)*100) Between 65.1 And 70,"65-70%",IIf(((Val([Deg1])/20)*100) Between 70.1 And 75,"70-75%",IIf(((Val([Deg1])/20)*100) Between 75.1 And 80,"75-80%",IIf(((Val([Deg1])/20)*100) Between 80.1 And 85,"80-85%",IIf(((Val([Deg1])/20)*100) Between 85.1 And 90,"85-90%",IIf(((Val([Deg1])/20)*100) Between 90.1 And 95,"90-95%",IIf(((Val([Deg1])/20)*100) Between 95.1 And 99.99,"95-99%","100%"))))))))))))

    Dim Grade As Double
    
    Grade = ((Val(Deg) / Final_Grade) * 100)
    
    If Deg = "غـ" Then
        Per = "متخلف"
    
    ElseIf Grade < 50 Then
        Per = "Less50"
    
    ElseIf Grade >= 50 And Grade <= 55 Then
        Per = "50-55%"
    
    ElseIf Grade >= 55.1 And Grade <= 60 Then
        Per = "55-60%"
    
    ElseIf Grade >= 60.1 And Grade <= 65 Then
        Per = "60-65%"
    
    ElseIf Grade >= 65.1 And Grade <= 70 Then
        Per = "65-70%"
    
    ElseIf Grade >= 70.1 And Grade <= 75 Then
        Per = "70-75%"
    
    ElseIf Grade >= 75.1 And Grade <= 80 Then
        Per = "75-80%"
    
    ElseIf Grade >= 80.1 And Grade <= 85 Then
        Per = "80-85%"
    
    ElseIf Grade >= 85.1 And Grade <= 90 Then
        Per = "85-90%"
    
    ElseIf Grade >= 90.1 And Grade <= 95 Then
        Per = "90-95%"
    
    ElseIf Grade >= 95.1 And Grade <= 99.99 Then
        Per = "95-99%"
    
    Else
        Per = "100%"
    
    End If
    
'Debug.Print "Grade of: " & Deg & "/" & Final_Grade & " = " & Per
End Function

وهذه نتيجة كل درجة على حدة:

Grade of: 13/20 = 60-65%
Grade of: 11/20 = 50-55%
Grade of: 11/20 = 50-55%
Grade of: 10/20 = 50-55%
Grade of: 0/20 = Less50
Grade of: 0/20 = Less50
Grade of: 9/20 = Less50
Grade of: 8/20 = Less50
Grade of: 7/20 = Less50
Grade of: 6/20 = Less50
Grade of: 5/20 = Less50
Grade of: 12/20 = 55-60%
Grade of: 12/20 = 55-60%
Grade of: 3/20 = Less50
Grade of: 2/20 = Less50
Grade of: 1/20 = Less50
Grade of: 4/20 = Less50
Grade of: 6/30 = Less50
Grade of: 1/30 = Less50
Grade of: 2/30 = Less50
Grade of: 3/30 = Less50
Grade of: 20/30 = 65-70%
Grade of: 20/30 = 65-70%
Grade of: 9/30 = Less50
Grade of: 0/30 = Less50
Grade of: 7/30 = Less50
Grade of: 15/30 = 50-55%
Grade of: 8/30 = Less50
Grade of: 20/30 = 65-70%
Grade of: 19/30 = 60-65%
Grade of: 18/30 = 55-60%
Grade of: 16/30 = 50-55%
Grade of: 14/30 = Less50
Grade of: ÛÜ/30 = ãÊÎáÝ
Grade of: ÛÜ/30 = ãÊÎáÝ
Grade of: ÛÜ/30 = ãÊÎáÝ
Grade of: 5/30 = Less50
Grade of: 17/30 = 55-60%
Grade of: 14/50 = Less50
Grade of: 10/50 = Less50
Grade of: 11/50 = Less50
Grade of: 13/50 = Less50
Grade of: 20/50 = Less50
Grade of: 15/50 = Less50
Grade of: 16/50 = Less50
Grade of: 17/50 = Less50
Grade of: 18/50 = Less50
Grade of: 19/50 = Less50
Grade of: ÛÜ/50 = ãÊÎáÝ
Grade of: 19/50 = Less50
Grade of: 12/50 = Less50
Grade of: 75/100 = 70-75%
Grade of: 75/100 = 70-75%
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: 50/100 = 50-55%
Grade of: 60/100 = 55-60%
Grade of: 70/100 = 65-70%
Grade of: 65/100 = 60-65%
Grade of: 40/100 = Less50
Grade of: 85/100 = 80-85%
Grade of: 85/100 = 80-85%
Grade of: 90/100 = 85-90%
Grade of: 90/100 = 85-90%
Grade of: 95/100 = 90-95%
Grade of: 95/100 = 90-95%
Grade of: 100/100 = 100%
Grade of: 100/100 = 100%
Grade of: 60/100 = 55-60%
Grade of: 50/100 = 50-55%
Grade of: 40/100 = Less50
Grade of: 0/100 = Less50
Grade of: 15/100 = Less50
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: 55/100 = 50-55%
Grade of: 65/100 = 60-65%
Grade of: 18/100 = Less50
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: 80/100 = 75-80%
Grade of: 80/100 = 75-80%
Grade of: 30/100 = Less50
Grade of: 13/20 = 60-65%
Grade of: 11/20 = 50-55%
Grade of: 11/20 = 50-55%
Grade of: 10/20 = 50-55%
Grade of: 0/20 = Less50
Grade of: 0/20 = Less50
Grade of: 9/20 = Less50
Grade of: 8/20 = Less50
Grade of: 7/20 = Less50
Grade of: 6/20 = Less50
Grade of: 5/20 = Less50
Grade of: 12/20 = 55-60%
Grade of: 12/20 = 55-60%
Grade of: 3/20 = Less50
Grade of: 2/20 = Less50
Grade of: 1/20 = Less50
Grade of: 4/20 = Less50
Grade of: 6/30 = Less50
Grade of: 1/30 = Less50
Grade of: 2/30 = Less50
Grade of: 3/30 = Less50
Grade of: 20/30 = 65-70%
Grade of: 20/30 = 65-70%
Grade of: 9/30 = Less50
Grade of: 0/30 = Less50
Grade of: 7/30 = Less50
Grade of: 15/30 = 50-55%
Grade of: 8/30 = Less50
Grade of: 20/30 = 65-70%
Grade of: 19/30 = 60-65%
Grade of: 18/30 = 55-60%
Grade of: 16/30 = 50-55%
Grade of: 14/30 = Less50
Grade of: ÛÜ/30 = ãÊÎáÝ
Grade of: ÛÜ/30 = ãÊÎáÝ
Grade of: ÛÜ/30 = ãÊÎáÝ
Grade of: 5/30 = Less50
Grade of: 17/30 = 55-60%
Grade of: 14/50 = Less50
Grade of: 10/50 = Less50
Grade of: 11/50 = Less50
Grade of: 13/50 = Less50
Grade of: 20/50 = Less50
Grade of: 15/50 = Less50
Grade of: 16/50 = Less50
Grade of: 17/50 = Less50
Grade of: 18/50 = Less50
Grade of: 19/50 = Less50
Grade of: ÛÜ/50 = ãÊÎáÝ
Grade of: 19/50 = Less50
Grade of: 12/50 = Less50
Grade of: 75/100 = 70-75%
Grade of: 75/100 = 70-75%
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: 50/100 = 50-55%
Grade of: 60/100 = 55-60%
Grade of: 70/100 = 65-70%
Grade of: 65/100 = 60-65%
Grade of: 40/100 = Less50
Grade of: 85/100 = 80-85%
Grade of: 85/100 = 80-85%
Grade of: 90/100 = 85-90%
Grade of: 90/100 = 85-90%
Grade of: 95/100 = 90-95%
Grade of: 95/100 = 90-95%
Grade of: 100/100 = 100%
Grade of: 100/100 = 100%
Grade of: 60/100 = 55-60%
Grade of: 50/100 = 50-55%
Grade of: 40/100 = Less50
Grade of: 0/100 = Less50
Grade of: 15/100 = Less50
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: 55/100 = 50-55%
Grade of: 65/100 = 60-65%
Grade of: 18/100 = Less50
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: ÛÜ/100 = ãÊÎáÝ
Grade of: 80/100 = 75-80%
Grade of: 80/100 = 75-80%
Grade of: 30/100 = Less50

 

جعفر

1022.Problem 55-2003.mdb.zip

  • 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.

×
×
  • اضف...

Important Information