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

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

قام بنشر

يوجد لدي 6 مربعات للتحرير والسرد أول 3 مربعات أمورهن طيبة ويعملن بكفائة (cmbsection-cmbtype-cmbsystemS)  أريد إضافة المربعات 3 المتبقية (cmbBRANDS-CMBMODELS-cmbclass) إلى كود المتغيراتWORK_2021_08.03_20h04m25s_001_.jpg.72a5073bbfdd97fff9f9bca0ce224033.jpg

Public Sub choixemp()

Dim sql As String, sql1 As String, ss As String, sqf As String
sql1 = "update Q1 set choix=true "

If (IsNull(cmbsection)) And (IsNull(cmbtype)) And (IsNull(CmbsystemS)) Then
sql = "update Q1 set choix=true "

ElseIf (Not (IsNull(cmbsection))) And (Not (IsNull(cmbtype))) And (Not (IsNull(CmbsystemS))) Then
sql = "update Q1 set choix=true where type= '" & cmbtype & "' and ids= " & cmbsection & " and SystemS like '" & CmbsystemS & "*'"

ElseIf (IsNull(cmbsection)) And (IsNull(CmbsystemS)) Then
sql = "update Q1 set choix=true where type='" & cmbtype & "' "

ElseIf (IsNull(cmbtype)) And (IsNull(CmbsystemS)) Then
sql = "update Q1 set choix=true where ids= " & cmbsection

ElseIf (IsNull(cmbtype)) And (IsNull(cmbsection)) Then
sql = "update Q1 set choix=true where SystemS like '" & CmbsystemS & "*'"

ElseIf (IsNull(cmbtype)) Then
sql = "update Q1 set choix=true where SystemS like '" & CmbsystemS & "*' and ids= " & cmbsection

ElseIf (IsNull(CmbsystemS)) Then
sql = "update Q1 set choix=true where type= '" & cmbtype & "' and ids= " & cmbsection

ElseIf (IsNull(cmbsection)) Then
sql = "update Q1 set choix=true where type= '" & cmbtype & "' and SystemS like '" & CmbsystemS & "*'"

End If

DoCmd.RunSQL sql

End Sub

'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Public Sub listeemp(xx As String)

Dim sql As String, sql1 As String, ss As String, sqf As String
sql1 = "select * from " & xx & " "

If (IsNull(cmbsection)) And (IsNull(cmbtype)) And (IsNull(CmbsystemS)) Then
sql = "select * from " & xx & " "

ElseIf (Not (IsNull(cmbsection))) And (Not (IsNull(cmbtype))) And (Not (IsNull(CmbsystemS))) Then
sql = "select * from " & xx & " where type= '" & cmbtype & "' and ids= " & cmbsection & " and SystemS like '" & CmbsystemS & "*'"

ElseIf (IsNull(cmbsection)) And (IsNull(CmbsystemS)) Then
sql = "select * from " & xx & " where type='" & cmbtype & "' "

ElseIf (IsNull(cmbtype)) And (IsNull(CmbsystemS)) Then
sql = "select * from " & xx & " where ids= " & cmbsection

ElseIf (IsNull(cmbtype)) And (IsNull(cmbsection)) Then
sql = "select * from " & xx & " where SystemS like '" & CmbsystemS & "*'"

ElseIf (IsNull(cmbtype)) Then
sql = "select * from " & xx & " where SystemS like '" & CmbsystemS & "*' and ids= " & cmbsection

ElseIf (IsNull(CmbsystemS)) Then
sql = "select * from " & xx & " where type= '" & cmbtype & "' and ids= " & cmbsection

ElseIf (IsNull(cmbsection)) Then
sql = "select * from " & xx & " where type= '" & cmbtype & "' and SystemS like '" & CmbsystemS & "*'"


End If

Me.RecordSource = sql
DoCmd.RunSQL "update EMPDEV set choix =false"
choix1.Value = False
lblselect.Caption = "تحديد الكل"

End Sub


 

IT_v24_fe - Copy_0001.rar

قام بنشر

رفع الله مقامكم كما رفع الســــــــماء ..وتقبل منكم الصلاة والدعاء ..ووســـــع رزقكم عدد مانزل من الماء ... وطوى صحائف أعمالكم نقية بيضاء

انشئ حساب جديد او قم بتسجيل دخولك لتتمكن من اضافه تعليق جديد

يجب ان تكون عضوا لدينا لتتمكن من التعليق

انشئ حساب جديد

سجل حسابك الجديد لدينا في الموقع بمنتهي السهوله .

سجل حساب جديد

تسجيل دخول

هل تمتلك حساب بالفعل ؟ سجل دخولك من هنا.

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

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

Important Information