You need to sign in to do that
Don't have an account?
Sami Shakith
Can we specify the distionation(directory) for file to download in APEX class?
Hi all,
I need to download a document in specified distination. How can i achive this? Please anyone help me.
I need to download a document in specified distination. How can i achive this? Please anyone help me.
If so - I'm afraid that is simply not possible. It is the clients browser which determines where downloaded files are saved, obviously it would be wildly confusing, and an incredible security issue if the supplying website could change where that file went. You could send them off to system folders, or hide malicious code all over someones HDD!
The only way to set the download destination is in your browser configuration. I'm afraid I have never heard in all my years of development a way to do that from the browser :(
Thank you for your reply.
It is definitely possible I think so. In DataLoader we have one option like "choose a target for extraction" with a browser button. That functionality i want to bring inside VF page. Cant we implement like that?
If you mean Dataloader.io, "Add Destination Folder" is just for FTP or Cloud storage solutions (like dropbox)
The only way forward I could see to do this would be to try to write an old school style Applet (do they even exist any more?) or use Flash to write up a piece of "file download" software that facilitated the pick-a-folder dialogue box, and then house that somewhere on the internet, and embed that in a Visualforce page using Canvas.... (but that is honestly a joke answer, please don't try to do that!!)