I know how to add a shape to a slide, but I know in Google Slides you are able to link another slide to display once you click on that text box. Is it possible to in App Script create a shape and then attach a link to it?
I have looked at the API documentation and was confused as to if it was possible.
This is a Sheets/Slides Add-On.
What I need to do is when a button is pressed on my Add On menu that I created, is to create a Slide in Google Slides, and use the information from a Sheets. I want to create a TextBox, and have when you click it link to another slide in the Slide Show. I just want it all automated.
If it is possible, how do I apply it to a shape I created?
var elementId = 'MyTextBox_001';
var pt350 = {
magnitude: 350,
unit: 'PT'
};
var requests = [{
createShape: {
objectId: elementId,
// tried linkUrl: "link";
shapeType: 'TEXT_BOX',
elementProperties: {
pageObjectId: "slide_001_001",
size: {
height: pt350,
width: pt350
},
transform: {
scaleX: 1,
scaleY: 1,
translateX: 350,
translateY: 100,
unit: 'PT'
}
}
}
},
// Insert text into the box, using the supplied element ID.
{
insertText: {
objectId: elementId,
// tried linkUrl: "link";
insertionIndex: 0,
text: SpreadsheetApp.getActiveSheet().getRange(3,2).getValue()
}
}];
// have tried elementId.setLinkUrl(linkHere);