Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7407399
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T05:42:51+00:00 2026-05-29T05:42:51+00:00

I am using PF 3.0.RC1 / NetBeans 7.0.1 and when I try to set

  • 0

I am using PF 3.0.RC1 / NetBeans 7.0.1 and when I try to set fileUploadListener for fileUpload component , NetBeans gives this warning “Unknown Property ‘handleFileUpload’ ” at leftmost of line.

In debug mode when I use fileUpload , it don’t call handleFileUpload method and nothing becomes.

What can I do for this problem ?

The code in the xhtml page :

 <p:fileUpload fileUploadListener="#{BDS_System.handleFileUpload}" mode="advanced" 
                        sizeLimit="500000" allowTypes="/(\.|\/)(gif|jpe?g|png)$/"/>

The code in the managed bean :

public void handleFileUpload(FileUploadEvent event) {
        String fileName = event.getFile().getFileName();
        byte[] fileBytes = event.getFile().getContents();

        ...
    }

Solved and solution :

Adding

<h:form enctype="multipart/form-data">

and two libraries ,commons-fileupload and commons-io .For maven projects ;

    <dependency>
        <groupId>commons-fileupload</groupId>
        <artifactId> commons-fileupload</artifactId>
        <version>1.2.1</version>
    </dependency>
    <dependency>
        <groupId>commons-io</groupId>
        <artifactId> commons-io</artifactId>
        <version>2.1</version>
    </dependency>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T05:42:52+00:00Added an answer on May 29, 2026 at 5:42 am

    my guess that it is that just like in BalusC answer in this thread: “Unknown Property” the error message of netbeans is nonsense , I think you forgot something in the fileupload config , like the

    Getting started with FileUpload

    First thing to do is to configure the fileupload filter which parses the multipart request. FileUpload filter should map to Faces Servlet.

    <filter>
        <filter-name>PrimeFaces FileUpload Filter</filter-name>
        <filter-class>org.primefaces.webapp.filter.FileUploadFilter</filter-class>
    </filter>
    <filter-mapping>
        <filter-name>PrimeFaces FileUpload Filter</filter-name>
        <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>
    

    and make sure to add enctype to your form like this:

    <h:form enctype="multipart/form-data">
    

    if all of the above wont help , take a look at BalusC answer in here: How to use PrimeFaces p:fileUpload

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using Primefaces 3.0.RC1 and on a form I have a <p:fileUpload mode=advanced auto=true>
I am using Visual Studio 2010 RC1. I define a resource Brush2 in app.xaml_:
I am new to Nhibernate and I am using Nhibernate 2.1.0 RC1. In C#
Using JDeveloper , I started developing a set of web pages for a project
I am using PF RC1, JSF 2.0. When I click on the today button
Using Scala 2.8 RC1 or newer, what is the best (easiest and/or most direct)
I'm using rails 3.2.0.rc1 and factory_girl_rails I want the location of my factories to
I've been using Scala 2.8RC1 and Scala Eclipse plugin for 2.8 RC1 happily for
Using XScalaWT , this compiled under Scala 2.7: class NodeView(parent: Composite) extends Composite(parent) {
This is Rails 2.3.8, I am using Bundler 1.0.21 and RubyGems 1.6.2 on a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.