Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. i can edit requiredfieldvalidator message at run time

i can edit requiredfieldvalidator message at run time

Scheduled Pinned Locked Moved C#
helptutorial
3 Posts 2 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    codes w
    wrote on last edited by
    #1

    Name

    E-mail

    This is my code. In this, i can make changes in RequiredFieldValidator's or regularexpressionvalidator's error messages. That is, the error message changed as editable format at runtime. I don't know how to solve this problem. please help, this important to me

    C 1 Reply Last reply
    0
    • C codes w

      Name

      E-mail

      This is my code. In this, i can make changes in RequiredFieldValidator's or regularexpressionvalidator's error messages. That is, the error message changed as editable format at runtime. I don't know how to solve this problem. please help, this important to me

      C Offline
      C Offline
      Colin Angus Mackay
      wrote on last edited by
      #2

      The error messages are exposed as properties, and any server side code can modify them. See: RequiredFieldValidator.ErrorMessage[^] So, in your code behind you can change the value of the error message before the page is rendered to the clint. e.g.

      myRequiredFieldValidator.ErrorMessage = "A different error message";

      Does this help?


      Do you want to know more?


      Vogon Building and Loan advise that your planet is at risk if you do not keep up repayments on any mortgage secured upon it. Please remember that the force of gravity can go up as well as down.

      C 1 Reply Last reply
      0
      • C Colin Angus Mackay

        The error messages are exposed as properties, and any server side code can modify them. See: RequiredFieldValidator.ErrorMessage[^] So, in your code behind you can change the value of the error message before the page is rendered to the clint. e.g.

        myRequiredFieldValidator.ErrorMessage = "A different error message";

        Does this help?


        Do you want to know more?


        Vogon Building and Loan advise that your planet is at risk if you do not keep up repayments on any mortgage secured upon it. Please remember that the force of gravity can go up as well as down.

        C Offline
        C Offline
        codes w
        wrote on last edited by
        #3

        thank u for ur idea Colin Angus Mackay, but this also produce the same error.ie., i can edit that error message help me

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups