WebFile.FileName

From Xojo Documentation

You are currently browsing the old Xojo documentation site. Please visit the new Xojo documentation site!

Property (As String )
aWebFile.FileName = newStringValue
or
StringValue = aWebFile.FileName

New in 2010r5

Supported for all project types and targets.

The name of the file.

Example

Create a new file for downloading:

TextFile = New WebFile // TextFile is a property of the web page
TextFile.MimeType = "text/plain"
TextFile.ForceDownload = True // If False, the browser may try to display the file instead of download it
TextFile.FileName = "TextFile.txt"

TextFile.Data = "Hello, world!"

ShowURL(TextFile.URL) // This causes the file to be downloaded