1. #1
    Ext User
    Join Date
    Oct 2008
    Location
    Warsaw(PL)/Cottbus(GER)
    Posts
    215
    Vote Rating
    0
    EagleEye666666 is on a distinguished road

      0  

    Default Using a ProgressBar with FileUpload

    Using a ProgressBar with FileUpload


    Hej guys,

    some question. I would like to let the user know how the upload is going, cuz in my WebApp the size of the uploaded files could be quite big. There is any chance to solve such issue?

    I can't find a way.

    A FormPanel only offers:
    Code:
    BeforeSubmit : FormEvent(this)
    Fires before the form is submitted. Only applies when using HTML submits. Listeners can set the doit field to false to cancel the action.
    
    * formPanel : this
    
    Submit : FormEvent(this, resultHtml)
    Fires after the form has been submitted. Only applies when using HTML submits.
    
    * formPanel : this
    * resultHtml : the response html
    So there is no anyway to let the client recieve some response from the server regarding to the upload progress? Serverside coding i have done so far. Even some JSON Response...

    Iam using Commons FileUpload with it's ProgressListener, so from the serverside it would be possible. I can't see a way on clientside to recieve sth from server

    Any Ideas ?? I would be really grateful about some discussion.
    Have a good start of the week guys!

  2. #2
    Ext GWT Premium Member gslender's Avatar
    Join Date
    Mar 2008
    Location
    Brisbane, Australia
    Posts
    1,572
    Vote Rating
    2
    gslender is on a distinguished road

      0  

    Default


    I think most methods poll the server asking how much of the total has been recieved etc.. so its a combination of server side knowing the amount transferred, sending back the results etc and the client side updating a progress bar.

    I could be wrong, but I believe that is the common method used to give feedback like this...

  3. #3
    Ext User
    Join Date
    Oct 2008
    Location
    Warsaw(PL)/Cottbus(GER)
    Posts
    215
    Vote Rating
    0
    EagleEye666666 is on a distinguished road

      0  

    Default


    Quote Originally Posted by gslender View Post
    I think most methods poll the server asking how much of the total has been recieved etc.. so its a combination of server side knowing the amount transferred, sending back the results etc and the client side updating a progress bar.

    I could be wrong, but I believe that is the common method used to give feedback like this...
    Hmm but i cant use extra or new html requests to the same controller(using spring). I mean the serverside i have go a listener on the upload proccess. But how to implement client side to recieve this response? I will than need a new request for it or iam wrong?

    Thats why i said a clientside component like the http://max-bazhenov.com/dev/upload-dialog-2.0/index.php this would be really nice. but as u can see here is also not a constant feedback how the concrete progress of one file is.

    Damn difficult (iam not happy with the (i have changed flextable to gxt table) table iam not satisfied with the solution.)

    Uploading sth is working .. but i have to add state stuff etc.... damn it is a hell of crazy implementing... (iam ed up right now)
    Attached Images

  4. #4
    Ext GWT Premium Member gslender's Avatar
    Join Date
    Mar 2008
    Location
    Brisbane, Australia
    Posts
    1,572
    Vote Rating
    2
    gslender is on a distinguished road

      0  

    Default


    there is no way to ask the browser how many bytes have been sent. that is why accurate methods poll the server for the amount sent.

    other option is to just show a busy progress bar that just continues to update without ever ending - and at least this would be a feedback to the user ?

  5. #5
    Ext User
    Join Date
    Oct 2008
    Location
    Warsaw(PL)/Cottbus(GER)
    Posts
    215
    Vote Rating
    0
    EagleEye666666 is on a distinguished road

      0  

    Default


    yeah i agree. maybe i will try to open this fileupload within a dialog.

    I wasted some time to accomplish this func. what this dialog has... when clicking Add directly opening file input..., but it is hell of complicated stuff and i do not know enough about the underlaying JS :/ I tried to inherit Button set Type to file... and added properties like this uploaddialog there has in JS code. Iam not able to understand all of the JS methods of this button

    I give it up.

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar