Advertisement
Advertisement
|
[x]
Attachment Details
|
||
|
[x]
The Solution Rating System
|
||
|
With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.
Your Input Matters If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support. Thank you! |
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: 65: 66: 67: 68: 69: 70: 71: 72: 73: 74: 75: 76: 77: 78: 79: 80: 81: 82: 83: 84: 85: 86: 87: 88: 89: 90: 91: 92: 93: 94: 95: 96: 97: 98: |
****code for module*******
Public Sub stoo()
Dim rs As New ADODB.Recordset
Dim sql As String
Dim objlst As ListViewItem
Dim objlst1 As ListViewItem
Form1.spel.Items.Clear()
Form1.stgl.Items.Clear()
Form1.ListView2.Items.Clear()
Form1.studentnotes.Text = ""
sql = "select * from [Student_Outcomes] where [StudentID] = " & Form1.TextBox7.Text
Debug.Print(sql)
rs.Open(sql, cnn1, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockPessimistic)
Do Until rs.EOF
With Form1.ListView1
objlst = Form1.ListView2.Items.Add(rs.Fields("OutcomeDesc").Value)
objlst.SubItems.Add(rs.Fields("outcomedate").Value)
objlst.SubItems.Add(rs.Fields("OutcomeAuth").Value)
objlst.SubItems.Add(rs.Fields("OutcomeProgram").Value)
objlst.SubItems.Add(rs.Fields("id").Value)
End With
rs.Update()
rs.MoveNext()
Loop
rs.Close()
sql = "select * from [Student_Programs] where [StudentID] = " & Form1.TextBox7.Text
Debug.Print(sql)
rs.Open(sql, cnn1, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockPessimistic)
Do Until rs.EOF
With Form1.spel
objlst1 = Form1.spel.Items.Add(rs.Fields("StudentProg").Value)
objlst1.SubItems.Add(rs.Fields("StudentProgRego").Value)
End With
rs.Update()
rs.MoveNext()
Loop
rs.Close()
sql = "select * from [Student_TargetGroups] where [StudentID] = " & Form1.TextBox7.Text
Debug.Print(sql)
rs.Open(sql, cnn1, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockPessimistic)
Do Until rs.EOF
With Form1.stgl
objlst1 = Form1.stgl.Items.Add(rs.Fields("StudentTG").Value)
'objlst1.SubItems.Add(rs.Fields("StudentProgRego").Value)
End With
rs.Update()
rs.MoveNext()
Loop
rs.Close()
End Sub
End Module
***** code for listview *****
Dim rs As New ADODB.Recordset
Dim datesel As Date
Dim sql As String
Dim idd As String
Dim test As String
studentnotes.Text = ""
idd = ListView2.SelectedItems.Item(0).SubItems(4).Text
' Debug.Print(idd)
' test = ListView2.SelectedItems.Item(0).SubItems(1).Text
' Debug.Print(test)
datesel = Date.ParseExact(ListView2.SelectedItems.Item(0).SubItems(1).Text, "dd/MM/yyyy", My.Computer.Info.InstalledUICulture)
Debug.Print(datesel)
sql = "select * from [Student_Outcomes] where [OutcomeDate] = #" & datesel.ToString("dd-MM-yyyy") & "# And [StudentID] = " & TextBox7.Text & " And [id] = " & idd
Debug.Print(sql)
rs.Open(sql, cnn1, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockReadOnly)
studentnotes.Text = ""
If Not (rs.EOF And rs.BOF) Then
If Not IsDBNull(rs.Fields("OutcomeNotes").Value) Then
studentnotes.Text = rs.Fields("OutcomeNotes").Value
Debug.Print(rs.Fields("outcomenotes").Value)
End If
End If
rs.Close()
|