1. #1
    Sencha User
    Join Date
    Dec 2012
    Location
    India
    Posts
    8
    Vote Rating
    0
    tanujkhanna9 is on a distinguished road

      0  

    Default Upload a file from combo Button

    Upload a file from combo Button


    We have a requirement where in we have a Combo Box having labels such as "Import" and "Export".

    Now upon clicking this label "Import". We would want a 'Browser Open' window should appear, allowing user to select the file to Upload.

    And Upon its selection, the file should be submitted to server.

    Please suggest how to proceed on this.

    Tanuj Khanna

  2. #2
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    9,154
    Vote Rating
    475
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    Perhaps look at the filefield control and see what it does when you active browser open and duplicate this code in your UX.

    Scott

  3. #3
    Sencha User
    Join Date
    Dec 2012
    Location
    India
    Posts
    8
    Vote Rating
    0
    tanujkhanna9 is on a distinguished road

      0  

    Default


    Thanks i was able to resolve the issue, I just need to add some styling so that it resonates with a standard combo-box.

    Also i have this interesting query, I was sending a standard Post 'HTTP' request through a standard submit form rather than AJAX. So as its a standard form submit, I would like to handle the response,

    for all correct scenarios, it is well handled by browser i.e. download of a file, but in case of a Server error, how can ExtJs handle this response ?? i just need to save that error message from server.

  4. #4
    Sencha User
    Join Date
    Jan 2013
    Posts
    2
    Vote Rating
    0
    mousomihoq is on a distinguished road

      0  

    Default


    Any site have tutorial to upload file so you can see these tutorial or visit to nipuhoq.com