Click here to Skip to main content
15,893,668 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionCheckBoxList control - Which ListItem was clicked? Pin
Ekjon9-Jul-08 7:02
Ekjon9-Jul-08 7:02 
AnswerRe: CheckBoxList control - Which ListItem was clicked? Pin
Christian Graus9-Jul-08 8:01
protectorChristian Graus9-Jul-08 8:01 
GeneralRe: CheckBoxList control - Which ListItem was clicked? Pin
Ekjon9-Jul-08 8:44
Ekjon9-Jul-08 8:44 
GeneralRe: CheckBoxList control - Which ListItem was clicked? Pin
Christian Graus9-Jul-08 8:46
protectorChristian Graus9-Jul-08 8:46 
GeneralRe: CheckBoxList control - Which ListItem was clicked? Pin
Ekjon11-Jul-08 9:39
Ekjon11-Jul-08 9:39 
GeneralRe: CheckBoxList control - Which ListItem was clicked? Pin
Herman<T>.Instance10-Jul-08 3:16
Herman<T>.Instance10-Jul-08 3:16 
GeneralRe: CheckBoxList control - Which ListItem was clicked? Pin
Ekjon11-Jul-08 10:11
Ekjon11-Jul-08 10:11 
QuestionCustomValidator ClientSideFunction property isn't working with ValidationSummary control Pin
Mark J. Miller9-Jul-08 6:00
Mark J. Miller9-Jul-08 6:00 
I have a CustomValidator control which is declared like this:

<br />
<asp:CustomValidator ID="m_DelayCodeValidator" runat="server"<br />
  ControlToValidate="m_DelayCode" Text="*" ErrorMessage="Delay code"<br />
  EnableClientScript="true"<br />
  ClientValidationFunction="m_DelayCode_Validate" <br />
  OnServerValidate="m_DelayCode_Validate" /><br />


I have a ValidationSummary control on the page as well. But when I try and submit the form the error message from my custom validator isn't listed with the other error messages in the ValidationSummary. The custom validation script isn't being called either - the script is only called when the value of ControlToValidate changes. I need the script called on submit as well like the other validators are.

ValidationSummary:

<asp:ValidationSummary ID="validationSummary" runat="server" DisplayMode="BulletList"<br />
     HeaderText="Please enter the required values:" /><br />


ClientValidationFunction:

function m_DelayCode_Validate(sender, args)<br />
{<br />
    if(m_DowntimeCode.options[m_DowntimeCode.selectedIndex].text != "Opportunity Maintenance")<br />
    {<br />
        args.IsValid = true;<br />
        return;<br />
    }<br />
    <br />
    if(args.Value == "" || args.Value == null || args.Value == undefined)<br />
        args.IsValid = false;<br />
    else<br />
        args.IsValid = true;<br />
}<br />


Code responsibly: OWASP.org
Mark's blog: developMENTALmadness.blogspot.com

AnswerRe: CustomValidator ClientSideFunction property isn't working with ValidationSummary control Pin
Christian Graus9-Jul-08 8:08
protectorChristian Graus9-Jul-08 8:08 
GeneralRe: CustomValidator ClientSideFunction property isn't working with ValidationSummary control Pin
Mark J. Miller9-Jul-08 8:45
Mark J. Miller9-Jul-08 8:45 
GeneralRe: CustomValidator ClientSideFunction property isn't working with ValidationSummary control Pin
Christian Graus9-Jul-08 8:56
protectorChristian Graus9-Jul-08 8:56 
Questionstatic object reference problem Pin
familyof79-Jul-08 5:52
familyof79-Jul-08 5:52 
AnswerRe: static object reference problem Pin
Christian Graus9-Jul-08 6:00
protectorChristian Graus9-Jul-08 6:00 
GeneralRe: static object reference problem Pin
familyof79-Jul-08 6:06
familyof79-Jul-08 6:06 
GeneralRe: static object reference problem Pin
Christian Graus9-Jul-08 6:21
protectorChristian Graus9-Jul-08 6:21 
GeneralRe: static object reference problem Pin
Christian Graus9-Jul-08 6:25
protectorChristian Graus9-Jul-08 6:25 
GeneralRe: static object reference problem Pin
familyof79-Jul-08 6:34
familyof79-Jul-08 6:34 
GeneralRe: static object reference problem Pin
Christian Graus9-Jul-08 6:35
protectorChristian Graus9-Jul-08 6:35 
GeneralRe: static object reference problem Pin
familyof79-Jul-08 7:22
familyof79-Jul-08 7:22 
GeneralRe: static object reference problem Pin
Christian Graus9-Jul-08 7:23
protectorChristian Graus9-Jul-08 7:23 
Questionput name of picture in database Pin
strawberrysh9-Jul-08 4:49
strawberrysh9-Jul-08 4:49 
AnswerRe: put name of picture in database Pin
Christian Graus9-Jul-08 4:55
protectorChristian Graus9-Jul-08 4:55 
AnswerRe: put name of picture in database Pin
Mark J. Miller9-Jul-08 6:05
Mark J. Miller9-Jul-08 6:05 
Questionshowing a dropdownlist in gridview Pin
eyeseetee9-Jul-08 4:25
eyeseetee9-Jul-08 4:25 
GeneralRe: showing a dropdownlist in gridview Pin
Christian Graus9-Jul-08 4:35
protectorChristian Graus9-Jul-08 4:35 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.