function bulkUploadFromGoogleDrive() {
// See https://developers.google.com/adwords/scripts/docs/features/bulk-upload
// for the list of supported bulk upload templates.
// You can upload a CSV file, or an EXCEL sheet.
var file = DriveApp.getFilesByName('testad2.csv').next();
var upload = AdWordsApp.bulkUploads().newFileUpload(file);
upload.forCampaignManagement();
// Use upload.apply() to make changes without previewing.
upload.preview();
}
The column headings we have in that sheet are: Ad group, Ad Group ID, Ad group state. It does not seem to make the necessary changes. Can someone provide an example sheet we should be using to update the adgroup status and what column headings are required? According to the documentation it should update with only those two columns or am I incorrect?
I have even tried importing using the column headings from an exported adgroup. The script executes but makes no changes. The same csv makes changes when imported manually.
Thanks for you help/
Thank you for your reply. I am very new to scripting and am learning. Sorry to ask the obvious but could you give an example of:
calling the function Inside your main function
Thanks,
function main(){
bulkUploadFromGoogleDrive();
}
function bulkUploadFromGoogleDrive() {
// See https://developers.google.com/adwords/scripts/docs/features/bulk-upload
// for the list of supported bulk upload templates.
// You can upload a CSV file, or an EXCEL sheet.
var file = DriveApp.getFilesByName('testad2.csv').next();
var upload = AdWordsApp.bulkUploads().newFileUpload(file);
upload.forCampaignManagement();
// Use upload.apply() to make changes without previewing.
upload.preview();
}