Forum Stats

  • 3,770,384 Users
  • 2,253,101 Discussions
  • 7,875,433 Comments

Discussions

Struts + ActionErrors + JDeveloper 10.1.3.4

655688
655688 Member Posts: 35
edited Sep 9, 2008 6:14PM in JDeveloper and ADF
Hi, i'm working with Stuts and JDeveloper 10.1.3.4. My actions (DataPages) classes extends PageController. I wanna show struts error messages like using the saveErrors() method, but this method was removed since 10.1.3 version. How can i do that?. (sorry for my english, i'm Argentinian).

Thanks for your help.
Tagged:

Answers

  • Jan Vervecken
    Jan Vervecken Member Posts: 2,842
    edited Sep 9, 2008 2:09AM
    hi hguaymas

    Looks like you have some code that works for you in some particular version (which version?), but that does not work in JDeveloper 10.1.3.4.0, right?
    Could you post some relevant parts of that code? This could help to understand the context you are working in.

    regards
    Jan Vervecken
  • Jan Vervecken
    Jan Vervecken Member Posts: 2,842
    hi hguaymas

    Is this the same question as in this forum thread?
    "Struts Error Messages (10.1.3.4)"
    705002

    regards
    Jan Vervecken
  • 655688
    655688 Member Posts: 35
    Hi Jan. I worked very well with the 10.1.2 version. I'm developing now with 10.1.3.4 and i have some troubles with my actions. The 10.1.3.4 version has some changes. When you use a DataPage, your class extends PageController and that class doesn't have the same methods that extending DataForwardAction (10.1.2). For example, it doesn't have the saveErrors() method. I don't know another way to put my errors and confirmations messages on the page.
  • Jan Vervecken
    Jan Vervecken Member Posts: 2,842
    hi hguaymas

    You write "+I don't know another way to put my errors and confirmations messages on the page.+".
    Maybe you could post some short relevant pieces of code of how you do this in 10.1.2, this could help others to suggest an alternative in more recent JDeveloper versions, possibly using the API of this PageController :
    http://download.oracle.com/docs/cd/B25221_04/web.1013/b25779/oracle/adf/controller/v2/lifecycle/PageController.html

    regards
    Jan Vervecken
    Jan Vervecken
  • 655688
    655688 Member Posts: 35
    Hi Jan, here is an example of how to show an error message in Struts with 10.1.2 version.

    public void onSomeMethod(DataActionContext ctx) {
    ctx.getActionErrors().add(ActionErrors.GLOBAL_ERROR,new ActionError("some key"));
    saveErrors(ctx);
    }

    Regards
This discussion has been closed.