How to get the Filename from the FileUpload control?
How to get the Filename from the FileUpload control?
(OP)
I have multiple fileupload controls on my form and I want to get the attached file name from the first one. Is there anyway that I can do this?
I normally use this code, but this gets all the attachments:
Set item = webdoc.GetFirstItem( "$File" )
If Not item Is Nothing Then
filename = item.values(0)
End If
Please Help!!! Thanks in advance
I normally use this code, but this gets all the attachments:
Set item = webdoc.GetFirstItem( "$File" )
If Not item Is Nothing Then
filename = item.values(0)
End If
Please Help!!! Thanks in advance
RE: How to get the Filename from the FileUpload control?
@If(!@Attachments; @Return(""); "");
@If(@IsDocBeingEdited;
"<p>Remove attachments here:<br>" +
@Implode("<input type=\"checkbox\" name=\"%%Detach\" value=\""+@AttachmentNames+"\">"+@AttachmentNames; "<br>");
"<p>View attachments here:<br>" +
@Implode("<a href=\"" + @Text(@DocumentUniqueID) + "/$file/" + @AttachmentNames + "\">"+@AttachmentNames + "</a>"; "<br>"))
It's only valid on the web. I don't know if the same can be said for the client.
Fight?

What fight?