24-01-16, 11:41 PM
أهلا أخي الكريم , هذا تعديل الكود :
PHP كود :
Dim x As Integer
Dim sql As String
For x = 0 To List1.ListCount - 1
If List1.Selected(x) = True Then
If Trim$(sql) = "" Then
sql = "select EmpID from EmpTable where EmpId ='" & List1.List(x) & "'"
Else
sql = sql & " Or EmpId ='" & List1.List(x) & "'"
End If
End If
Next x
If Trim$(sql) = "" Then Exit Sub
ActiveReport1.DataControl1.Source = sql
ActiveReport1.Show
ActiveReport1.Refresh

