CGDevTools Forum

Welcome to the Official CGDevTools Support Community Forums.

Runtime file selection box

by Eric.P » 05 Dec 2016 12:46

Hi community !

On the client side (admin managment) i have a grid where each row correspond to a server system command like "upload file", "move file", "list files" etc...
So on the onScroll event of the dataset i would like to use the fileupload component if the command is "upload file".

I put the file upload component visible false on the form.
The behaviour expected is the same that if i click on the component when it's visible ( = Show the selection file dialog).

I didn't find a method to trigger the dialog :s

Do you have a trick to do that ?

Thanks.
CG 3.0.0.115 / IW 14.59 / XE8
Eric.P
 
Posts: 24
Joined: 24 Aug 2016 15:07

by Eric.P » 05 Dec 2016 14:35

Re,

One of my coworker found a trick that does the expected behaviour.
I can simulate the click by adding javascript code like that :

CGAddJavaScriptToAjaxResponse(IWCGJQFileUpload1.GetIDJQuery + '.find("input").click()');

Is there a properly method on the component like "TriggerFileDialog" on something like that in the last beta release ?

Thanks
CG 3.0.0.115 / IW 14.59 / XE8
Eric.P
 
Posts: 24
Joined: 24 Aug 2016 15:07

by Alexander Bulei » 05 Dec 2016 15:35

Hello,

Due some browser's restriction, there is no any "cross-browser" way to trigger the dialog..

Of course, you can trigger the click on client side, but in some browsers it will fail.

Best Regards.
Group: Developers | Support Team

  • info [at] cgdevtools.com - General information
  • sales [at] cgdevtools.com - Sales department
  • support [at] cgdevtools.com - Product and Technical Support
User avatar
Alexander Bulei
Site Admin
 
Posts: 3635
Joined: 15 May 2012 08:52
Location: Mealhada, Portugal

by Eric.P » 05 Dec 2016 15:51

Ok,

Thank you for the detail.
CG 3.0.0.115 / IW 14.59 / XE8
Eric.P
 
Posts: 24
Joined: 24 Aug 2016 15:07


Return to JQFileUpload

Who is online

Users browsing this forum: No registered users and 2 guests

Contact Us.