VB.NET:
MessageBox.Show("Are you sure to delete this record ? ", "Warning", MessageBoxButtons.YesNoCancel)
confirm()
VB.NET:
Private Function confirm()
If DialogResult.Yes Then
btnUpdate.Enabled = True
btnDelete.Enabled = True
btnPrint.Enabled = True
btnNew.Enabled = True
txtPOBranchID.Enabled = True
txtPOID.Enabled = True
colorTextField(False)
txtPOBranchID.Text = "Yes"
Exit Function
End If
If DialogResult.No Then
btnUpdate.Enabled = True
btnDelete.Enabled = True
btnPrint.Enabled = True
btnNew.Enabled = True
txtPOBranchID.Enabled = True
txtPOID.Enabled = True
txtPOBranchID.Text = "No"
colorTextField(False)
Exit Function
End If
End Function
Whatever i click "Yes" or "No" .... the result is "YES"
how come ??????