PDF file name in Browser using sendFile
We are using "Open URL in Window" click action to render the PDF byte stream in a browser by calling a activity which does the tools.sendFile function. We have requirement to show and download the exact file name passed for the aFileName in this function. We added headers for ContentType and ContentDisposition to be passed as params to sendFile. But then we see that's always taking the Thread Name while streaming the file in browser window. However Download is taking the file name correctly. It's just the browser is showing the thread name at the end of the URL. Exact issue discussed below but no solution. Can someone please help with the same or any alternate way of doing it?
https://support.pega.com/question/pdf-file-name-browser-usingsendfile