Hello,
Not sure if I have the correct forum for this.
We have a website where outside customers fill out a form that gets submitted to a SQL database, they can attach pdf or txt files to the data they are submitting. The attachments are stored in a folder on the webserver. Each submission has a unique id attached to it.
We also have a classic asp intranet page that displays the data that was submitted. I want to display a link on the asp page to any documents that were sent for a specific ID. I will always know the first 8 characters of the file name but will not know the rest of the file name or extension. There is a field that will tell me how many files were attached to the form. Here is my code:
X is a mapped drive from the intranet webserver to the server where the files are stored. If there was more than one file submitted then there should be a link to each file. There are 2 files for the ID I'm testing.
an example file name would be: 31181 - L_Valdez.pdf
(unique 5 digit id space dash space filename)
Any help would be appreciated.
Thanks!
Not sure if I have the correct forum for this.
We have a website where outside customers fill out a form that gets submitted to a SQL database, they can attach pdf or txt files to the data they are submitting. The attachments are stored in a folder on the webserver. Each submission has a unique id attached to it.
We also have a classic asp intranet page that displays the data that was submitted. I want to display a link on the asp page to any documents that were sent for a specific ID. I will always know the first 8 characters of the file name but will not know the rest of the file name or extension. There is a field that will tell me how many files were attached to the form. Here is my code:
Code:
<%
if strAttach > 0 then
%>
<a href="x:\'" & intMyID & "' & " - " & "?" ">
<%
else
%>
<td> No Attachment(s). </td>
<%
end if
%>
an example file name would be: 31181 - L_Valdez.pdf
(unique 5 digit id space dash space filename)
Any help would be appreciated.
Thanks!