none
Applying a RequiredFieldValidation control to a dropdown list or drop down list with option to add value RRS feed

  • Question

  • I have figured out how to drop a RequiredFieldValidation control onto a field in a webpart to check for value when saving but it only appears to work for an aspx text box control.  I have several fields that are drop down lists or lists with option to add your own value that I want to do that same.  I am unable to do this because when you look at the tag properties for the RequiredFieldValidation control - the drop-down-list for the ControlToValidate values does NOT contain the ControlID for the drop down list SharePoint control that I want to apply this too.  The list only shows ControlIDs for aspx controls.  If I try to just type into the tag property, I get an error when trying to save. 

    I have been unsuccessful in 'reformatting' an dropdown sharepoint list to an aspx dropdown list.

    So, my question is, how do I now capture an error when I want to force the user to enter or select a value from a drop down list (which is a SharePoint control vs an aspx control)?
    Monday, June 15, 2009 11:27 PM

Answers