AdsApp.​FileUpload

Represents a Bulk Upload of an already-existing file, loaded from Blob, Google Sheet or Drive File.

Methods:

MemberTypeDescription
applyvoidUploads the file and applies the changes.
forCampaignManagementAdsApp.FileUploadSpecifies that this upload is used for Campaign Management entity changes.
forOfflineConversionsAdsApp.FileUploadSpecifies that this upload is used for reporting offline conversions.
previewvoidUploads the file and previews the changes.
setFileNameAdsApp.FileUploadSets the file name of the uploaded file.

apply()

Uploads the file and applies the changes.

Returns nothing.

forCampaignManagement()

Specifies that this upload is used for Campaign Management entity changes.

This is the default option, so this method doesn't need to be called except to override a previous call to FileUpload.forOfflineConversions().

Return values:

TypeDescription
AdsApp.FileUploadThe same upload specified to change Campaign Management entities.

forOfflineConversions()

Specifies that this upload is used for reporting offline conversions.

By default, uploads are used for Campaign Management entity changes, so it's necessary to call FileUpload.forOfflineConversions() to make offline conversion uploads work correctly.

Return values:

TypeDescription
AdsApp.FileUploadThe same upload specified to report offline conversions.

preview()

Uploads the file and previews the changes.

Returns nothing.

setFileName(fileName)

Sets the file name of the uploaded file.

Arguments:

NameTypeDescription
fileNameStringThe file name of the uploaded file.

Return values:

TypeDescription
AdsApp.FileUploadThe same upload with the file name applied.