Public Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click tot1 = 21 If DropDownList1.SelectedValue = 0 Then tot1 = tot1 - 3 End If If DropDownList10.SelectedValue = 0 Then tot1 = tot1 - 3 End If If DropDownList11.SelectedValue = 0 Then tot1 = tot1 - 3 End If If DropDownList12.SelectedValue = 0 Then tot1 = tot1 - 4 End If If DropDownList13.SelectedValue = 0 Then tot1 = tot1 - 4 End If If DropDownList14.SelectedValue = 0 Then tot1 = tot1 - 2 End If If DropDownList15.SelectedValue = 0 Then tot1 = tot1 - 2 End If sem1 = ((DropDownList1.SelectedValue * 3) + (DropDownList10.SelectedValue * 3) + (DropDownList11.SelectedValue * 3) + (DropDownList12.SelectedValue * 4) + (DropDownList13.SelectedValue * 4) + (DropDownList14.SelectedValue * 2) + (DropDownList15.SelectedValue * 2)) / tot1 TextBox1.Text = sem1 End Sub
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)