This discussion is archived
9 Replies Latest reply: Aug 9, 2010 4:35 AM by Patrick Wolf RSS

Change default error messages

767431 Newbie
Currently Being Moderated
Hello..

I want to change the default error message in apex. for example I wanna change the Not-Null default error message so instead of "Field1 must have some value" I wanna get "Field1 must not be null".

Thanks
  • 1. Re: Change default error messages
    jariola Guru
    Currently Being Moderated
    Hi,

    You mean validation error message ? I think that is standard text when you have created form using wizard and table have not null columns.
    You can change that afterward.
    http://download.oracle.com/docs/cd/E14373_01/appdev.32/e11838/bldr_pgs.htm#CHDEBBCE

    Go edit validation and define text you like have in Error Message.

    Br,Jari
  • 2. Re: Change default error messages
    767431 Newbie
    Currently Being Moderated
    Thanks..
    Let me clarify it If I define I text field to be not null in apex I got an apex message that tells me that this field can't be null.
    I didn't define any validation. The only thing I want to change these default messages comes with apex
  • 3. Re: Change default error messages
    jariola Guru
    Currently Being Moderated
    Hi,

    It is not very clear for me what error message you mean.
    As I did say, if you did create form using wizard, it has probably generated automatically not null validations.

    Check your page validations.

    Br,Jari
  • 4. Re: Change default error messages
    Patrick Wolf Employee ACE
    Currently Being Moderated
    Hi "user12974236",

    have a look at "Translating Messages Used Internally by Oracle Application Express" - http://download.oracle.com/docs/cd/E17556_01/doc/user.40/e15517/global.htm#CHDJFHBD
    It's the message APEX.PAGE_ITEM_IS_REQUIRED which is used by the built-in standard not null validation.

    Regards
    Patrick
    -----------
    My Blog: http://www.inside-oracle-apex.com
    APEX 4.0 Plug-Ins: http://apex.oracle.com/plugins
  • 5. Re: Change default error messages
    Arie Geller Guru
    Currently Being Moderated
    Hi Patrick,

    It’s an interesting reply, especially as the OP marked it as correct, but still I’m trying to understand something.

    As far as I can tell, you can use the translation system only for messages that was defined under a different language from the application primary language. For example, if you are working in English, and you are defining new text messages under English, with new text content, the Application Builder will ignore them as long as your application language is English (i.e. you can’t change/edit the internally used messages of your primary language). So, is this particular text message different?

    Thanks,
    Arie.

    -------------------------------------------------------
    ♦ Please remember to mark appropriate posts as correct/helpful. For the long run, it will benefit us all.

    ♦ Author of Oracle Application Express 3.2 – The Essentials and More
  • 6. Re: Change default error messages
    Patrick Wolf Employee ACE
    Currently Being Moderated
    Hi Arie,

    yes it is. If a text message is defined for one of the new APEX.% internal messages, it will always be used. Independent of the primary language.
    It might be useful that we change to this new behavior for the other internal messages as well...

    Regards
    Patrick
    -----------
    My Blog: http://www.inside-oracle-apex.com
    APEX 4.0 Plug-Ins: http://apex.oracle.com/plugins

    Edited by: Patrick Wolf3 on Aug 9, 2010 1:15 PM
  • 7. Re: Change default error messages
    767431 Newbie
    Currently Being Moderated
    This solves the problem but how can I change the error display settings from Both inline with field & Notification Message to just notification message ?
  • 8. Re: Change default error messages
    Patrick Wolf Employee ACE
    Currently Being Moderated
    Hi,

    you can to that with the "Default Error Display Location" application property.

    1) pick you application
    2) click the "Edit Application Properties" button
    3) change the "Default Error Display Location" in the "Properties" section

    Regards
    Patrick
    -----------
    My Blog: http://www.inside-oracle-apex.com
    APEX 4.0 Plug-Ins: http://apex.oracle.com/plugins
  • 9. Re: Change default error messages
    Arie Geller Guru
    Currently Being Moderated
    Hi Patrick,

    Thanks for the clarification. Is there any other text messages group(s) that behaves the same?

    >> It might be useful that we change to this new behavior for the other internal messages as well...

    Yes, it will. First, it will give developers more flexibility with the application primary language, but more importantly, it will create unity in the behavior of these messages. Now you need to remember that some of them are behaving a bit differently.

    Thanks and regards,
    Arie.

    -------------------------------------------------------
    ♦ Please remember to mark appropriate posts as correct/helpful. For the long run, it will benefit us all.

    ♦ Author of Oracle Application Express 3.2 – The Essentials and More

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points