I hope anyone could help me...
I tried to Put an Img as the return value of a function inside a Spreadsheet cell...
The input of the function is a string and because of this Keyword, I will show an image... Not the image string directly the image like I could do it with =IMAGE(URL)
function IconAuswahl(a){
if (a === 'Test1') {
result = (Image("https://i.imgur.com/Jm5ND1E.png" ));
} else {
result = 'NOT positive';
}
}
function imgIn(){
let app = SpreadsheetApp;
let table = app.getActiveSpreadsheet();
let mySheet = table.getActiveSheet();
let cell = mySheet.getRange('A1');
cell.setValue('=Image("https://i.imgur.com/Jm5ND1E.png")') ;
}
With the last function, I'm able to put an image to any cell but I like to set this value inside the cell I call the function.
Thanks!