แสดงกระทู้

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - ต้นนาโน

หน้า: [1]
1


ผมสมมุติ Combobox ชื่อ Ohms และ textbox ของ Accept/Reject​ ชื่อ AandR
 
โค๊ด: [Select]
Private Sub Ohms_AfterUpdate()
   Dim lngRed As Long, lngGreen As Long
   
        lngRed = RGB(255, 0, 0)
        lngGreen = RGB(50, 205, 50)
     
       
If Me.Ohms >= "10E04" And Me.Ohms <= "10E09" Then
Me.AandR = "Accept"
AandR.BackColor = lngGreen
ElseIf Me.Ohms >= "10E10" And Me.Ohms <= "10E12" Then
Me.AandR = "Reject"
AandR.BackColor = lngRed
Else
Me.AandR.BackColor = Ohms.BackColor
Me.AandR = Null
End If
End Sub
โพสต์นี้ได้รับคำขอบคุณจาก: ต้นนาโน

หน้า: [1]