Skip to main content The Trailblazer Community will be unavailable from 2/1/2025 to 2/2/2025. Please plan your activities accordingly.
Hello

    I have used the Custom button (/sfc/servlet.shepherd/document/download/ ) to download all the files realed to an object. The Zip folder always has a name “downloaded-content”. So I need to change this name to “file.zip”.

    Is it possible to rename the Zip folder?

    It is pretty urgent.

    Thanks
4 answers
  1. Jun 8, 2022, 7:42 PM
    Hi Khushbu,

    Were you able to fix this problem? I am also facing the same issue, Looking for the fix. Any Inputs will be greatly helpful
  2. May 28, 2020, 11:50 AM
    Hi Khushbu,

    You can give a try but I don't think it will work.

    Also servlet.shepherd is undocumented so we do not have much information but as said earlier renaming zip might not be possible.

    Hope above information was helpful.

    Thanks,

    Vinay Kumar
  3. May 28, 2020, 10:51 AM
    Hi Vinay,

    I have tried to use the URL and added the filename you suggested, but it is not working anymore.

    I have used the Apex class and Lightning component to achieve the zip file feature. So will it help me rename using JSZip library?

    Thanks,

    Khushbu
  4. May 27, 2020, 7:55 PM
    Hi Khushbu,

    This might not be possible to rename zip.

    You can give try using JSZip and FileSaver (JS libraries) or URL parameters like ?name=foo.zip, ?filename=foo.zip, ?zip=foo.zip but this might not work as well.

    Hope above information was helpful.

    Please mark as Best Answer so that it can help others in the future.

    Thanks,

    Vinay Kumar
0/9000