I have a grid component with a button that calls the "File Download" Action Javascript configured to use an Ajax Callback to specify the path and file name. The original file name is stored in the database when the file is uploaded. The file is stored in the file system.
My xbasic function simply sets the following:
e.ajaxCallBackType = "FileDownload"
e.Folder = ** location of the folder where my files are stored on an internal server
e.CSFilename = ** the name of the file stored in the database record
This works like a charm. The file gets downloaded to the local pc with the correct file name and extension.
I wanted to change the grid to a list control and use the same methodology to handle this.
In the list control I add a field and in the onClick it calls a Javascript Action which calls the same File Download action javascript.
I used the same code in my xbasic function to set the ajaxCallBackType, Folder, and CSFilename to the same values used in the grid.
HOWEVER *$#(*)@#
When the file downloads from the list control to the local pc it loses the file extension. I took an example where the filename was longer and changed the csfilename to return temp.csv. When the file is downloaded to the local pc it removes the .csv and replaces it with an underscore (i.e. temp_) with no file extension. I can manually change the filename to temp.csv and it opens fine.
What is causing this difference between a grid and a list whereby the list file download loses my file extension?
Thanks,
Jeremy
My xbasic function simply sets the following:
e.ajaxCallBackType = "FileDownload"
e.Folder = ** location of the folder where my files are stored on an internal server
e.CSFilename = ** the name of the file stored in the database record
This works like a charm. The file gets downloaded to the local pc with the correct file name and extension.
I wanted to change the grid to a list control and use the same methodology to handle this.
In the list control I add a field and in the onClick it calls a Javascript Action which calls the same File Download action javascript.
I used the same code in my xbasic function to set the ajaxCallBackType, Folder, and CSFilename to the same values used in the grid.
HOWEVER *$#(*)@#
When the file downloads from the list control to the local pc it loses the file extension. I took an example where the filename was longer and changed the csfilename to return temp.csv. When the file is downloaded to the local pc it removes the .csv and replaces it with an underscore (i.e. temp_) with no file extension. I can manually change the filename to temp.csv and it opens fine.
What is causing this difference between a grid and a list whereby the list file download loses my file extension?
Thanks,
Jeremy