What is this error?
And how can I avoid it in this code?
After i hit okay it comes up with "Run time error 361 : could not load or unload object"
Can anyone help me with this?
Thanks
MO24
And how can I avoid it in this code?
VBA Code:
Private Sub AssessmentForm_Initialize()
AssessmentSubject.AddItem "Mathematics"
AssessmentSubject.AddItem "English"
AssessmentSubject.AddItem "Science"
AssessmentSubject.AddItem "Geography"
AssessmentSubject.AddItem "Commerce"
AssessmentSubject.AddItem "History"
AssessmentSubject.AddItem "Graphics"
AssessmentSubject.AddItem "PDH"
AssessmentSubject.AddItem "PE"
AssessmentSubject.AddItem "Other"
AssessmentLevel.AddItem "Assessment"
AssessmentLevel.AddItem "Formative"
AssessmentLevel.AddItem "Class"
AssessmentLevel.AddItem "Other"
AssessmentLevel.AddItem "Draft"
AssessmentLevel.AddItem "Plan(Assessment)"
AssessmentLevel.AddItem "Plan(Checkpoint)"
AssessmentLevel.AddItem "Checkpoint"
TypeOfAssessment.AddItem "Essay"
TypeOfAssessment.AddItem "Worksheet"
TypeOfAssessment.AddItem "Exercise"
TypeOfAssessment.AddItem "Exam"
TypeOfAssessment.AddItem "Quiz"
TypeOfAssessment.AddItem "Mindmap"
TypeOfAssessment.AddItem "Notes"
TypeOfAssessment.AddItem "Video"
TypeOfAssessment.AddItem "Read"
TypeOfAssessment.AddItem "Report"
TypeOfAssessment.AddItem "Other"
TypeOfAssessment.AddItem "Checkpoint"
TypeOfAssessment.AddItem "Speech"
TypeOfAssessment.AddItem "Summary"
TypeOfAssessment.AddItem "CAD"
End Sub
Private Sub AssessmentCancel_Click()
Unload Me
End Sub
Private Sub AssessmentClear_Click()
AssessmentSubject.Clear
AssessmentLevel.Clear
TypeOfAssessment.Clear
TextBox1.Value = ""
TextBox2.Value = ""
Call AssessmentForm_Initialize
End Sub
Private Sub AssessmentInsert_Click()
Sheet1.Activate
Cells(18, 2) = AssessmentSubject.Value
Cells(18, 3) = AssessmentLevel.Value
Cells(18, 4) = TypeOfAssessment.Value
Cells(18, 5) = TextBox1.Value
Cells(18, 6) = TextBox2.Value
ActiveWorkbook.Worksheets("Lists").ListObjects("Table1").Sort.SortFields.Clear
ActiveWorkbook.Worksheets("Lists").ListObjects("Table1").Sort.SortFields.Add2 _
Key:=Range("Table1[[#All],[Due Date]]"), SortOn:=xlSortOnValues, Order:= _
xlAscending, DataOption:=xlSortNormal
With ActiveWorkbook.Worksheets("Lists").ListObjects("Table1").Sort
.Header = xlYes
.MatchCase = False
.Orientation = xlTopToBottom
.SortMethod = xlPinYin
.Apply
End With
End Sub
After i hit okay it comes up with "Run time error 361 : could not load or unload object"
Can anyone help me with this?
Thanks
MO24