3 Replies Latest reply: Jan 29, 2014 6:44 AM by h0s RSS

inputFile, usesUpload and excel export on Glassfish

h0s Newbie
Currently Being Moderated

Hello,

 

I am working in an ADF application which is deployed on a Glassfish server. I use jdeveloper 11.1.2.3.0.

I have problems with two components : the af:inputFile and the af:exportCollectionActionListener.

 

Cause of af:inputFile I had to change the usesUpload property to true.

 

[code]<af:form id="f1" usesUpload="true">[/code]

 

In Glassfish, if usesUpload property is true, the af:inputFile component have a strange behavior where the web browser ask user to refresh the page.

 

The other problem is about export excel functionality.

 

[code]

<af:commandImageLink text="" id="cil4" icon="/adf/images/excel.png">

     <af:exportCollectionActionListener type="excelHTML" exportedId="t2"/>

</af:commandImageLink>

[/code]

 

In Glassfish, clicking on the export excel button raise a nullPointerException. This nullpointerException does not occur if the usesUpload property is set to false.

 

Knowing that there is no problem in weblogic, how can I use af:inputFile and af:exportCollectionActionListener components in an application which must be deployed on Glassfish? Is there a solution? or is it an ADF Essential's limitation?

  • 1. Re: inputFile, usesUpload and excel export on Glassfish
    Dana Singleterry Explorer
    Currently Being Moderated

    used the same code for the export to excel on 11.1.2.3 of adf-essentials deployed to Oracle GlassFish Server 3.1.2.2 (build 5)

     

     

                                                                    <af:menu text="My Options" id="m2">
                                                                        <af:commandMenuItem text="Export to Excel"
                                                                                            id="cmi1">
                                                                            <af:exportCollectionActionListener type="excelHTML"
                                                                                                               exportedId="t1"/>
                                                                        </af:commandMenuItem>

     

     

    Found no issues. Will give the inputfile a shot and let you know what I find.

  • 2. Re: inputFile, usesUpload and excel export on Glassfish
    h0s Newbie
    Currently Being Moderated

    Thanks for answer!

     

    Is your excel export in a form where "usesUpload" property is set to true? By default it is false and there is no issue. But to have inputFile working (well they don't work too but it's another problem) I understand that this parameter must be to true, and after switching this parameter to true, excel export does not work for me.

  • 3. Re: inputFile, usesUpload and excel export on Glassfish
    h0s Newbie
    Currently Being Moderated

    I have solved this issue adding this in the glassfish-web.xml file :

     

    <locale-charset-info>

          <parameter-encoding default-charset="utf-8"/>

    </locale-charset-info>

    <parameter-encoding default-charset="utf-8"/>

Legend

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