I have a situation in which I need to check for data in either of two fields
and display an alert if neither field contains data or if both fields contain
data when the user clicks on a View button; these two fields are for Member
to handle that situation. A new condition was thrown at me yesterday in
which I need to display a modal popup only if a Social Security Number is
entered so the user can select from either of two systems containing the
data. I have the modal popup constructed, but it displays when it shouldn't.
For instance, taking the case of both fields being empty or both fields
containing data: on clicking the View button, an alert is displayed (via the
modal popup gets displayed. In another case, the modal popup gets displayed
if the user enters a Member Number and clicks the View button.
In the aspx file, I have OnClick for the View button call the cmdView_Click
function in my code-behind. The OnClientClick is defined to "return
mentioned in the first paragraph. Since the AJAX ModalPopupExtender requires
a TargetControlID, I have it pointing at my View button.
depending on whether a Member Number or a Social Security Number is entered,
but is there anyway to somehow tie the AJAX ModalPopupExtender back in to my
display ONLY if a Social Security Number has been entered?