Can I assign scripts to inserted images within cells or hyperlinks in Google Sheets? - hyperlink

I'm curious if there's a way to “assign script” to an image inserted into a cell using the =IMAGE(“URL”) method for Google Sheets? If not, is there a way to “assign script” to a hyperlink?
What I’d like to do is create a table of contents tab inside a Google Sheet that has many other tabs. On the table of contents, I’d love to have inserted images that act as buttons to navigate to these different tabs. I can “assign script” to images that have been inserted through the menu toolbar (e.g., Insert > Image or Insert > Drawing). However, it’s extremely clunky to have to realign my images if a new row is inserted into the table of contents.
I could always just use hyperlinks to navigate to each tab, but I don’t like how it opens a new window every time you click on the hyperlink. And I don’t like how it requires two clicks of a hyperlink (one click for the hyperlink, and then another click for the web address that pops up) to arrive at the desired tab.
So I guess, is there any option that exists to insert an image inside a cell, which can then be assigned a script?
This functionality would be so helpful.
Thanks for you time!

I've been searching and haven't found a way to insert a link to anything with an Image placed with the =IMAGE () option. I've resorted to text and formatting .
You can assign a script to change tabs via "floating" Images that are Inserted via insert menu. then on the picture on the top right corner click the arrow and assign the script " goToPage1 " or whatever you decide to call your function and page. it's not as fast as Excel but it works
var ss = SpreadsheetApp.getActiveSpreadsheet();
function goToPage1(){
ss.setActiveSheet(ss.getSheetByName("Page1"));
}

My only solution to this problem is to insert image within cell, then insert a transparent drawing and assign the script to that. It's not ideal, but at least it means the images are aligned perfectly, the transparent floating image just needs to be in the general area

At this time, only to OverGrid images.

Related

I want to export a pdf from a google spreadsheet without the empty cells making it bigger than it needs to

I have a spreadsheet created with importrange functions that pulls data from another file. The problem I'm facing is that when I try to print out the spreadsheet and save as pdf, the pdf includes all the cells I've set up to receive my data, the empty ones too, and I end up with a 4 page pdf with 3 empty pages.
I tried to put a filter() function in front of the importrange, so that if the importrange somehow imports null values and puts them in the empty cells making them no empty even though they look like it, that would do it, it didn't.
I've also read that google spreadsheet interpretes white background color as fill color, and to set it back to default background, and I did, but it didn't solve it.
I've removed the importrange functions at all to see if it was that that was doing it, it wasn't.
Finally, I've thought about formatting, because those cells are formatted with white borders, but I removed all custom borders and it still prints out all the cells.
To reiterate, I need to be able to do print > save as pdf and get a pdf that contains only the cells used, and I have an old spreadsheet that I'm improving upon that does exactly this (that is not made by me) and has very similar formatting, so I don't understand what's the issue here.
Here's one workaround:
Select the cells you want to include in your PDF
Click on "File" > "Download" > "PDF"
When the Print Settings/Export window appears, select "Selected cells" instead of "Current sheet" under "Export" in the top right corner
This screen capture shows the window in question.
Bois, I figured it out.
It's a pretty dumb thing, but I didn't know it.
The solution is absolutely no formatting of any kind, it's ok to have formulas that dont output anything, and custom text color for the cell, but all the cells must be separated and with default background color and default border color (AKA no border option).
What kept bugging me is the fact that my reference project had no cell borders and it had this loong table that never printed out if not necessary, and I assumed it had white borders, but it didn't.
Turns out the option to hide cell borders (VIEW > SHOW > GRID LINES) at all is connected to the spreadsheet itself, not the user, so if you disable it, everytime you open the file, from every account connected, it is not gonna show, so that's how they did it.

Power Automate Desktop Fill Data from excel to website but multi UI ELEMENT

I am a newbie working on power automate desktop and sorry if my english is not good. Currently I am making a flow that will populate the website from my excel. Excel I will have a list of lists I want it to populate in order. But I am having a problem that when I finish filling in the first position, it will show the second position and go on to third , ..... The HTML Input ID also changes in ascending order. So when I do this Flow, it only executes at the top of all my list from excel. Is there a way that can automatically jump the column according to that line UI element. Thank you
enter image description here
Input text will increase like adGroupInfo.1.adcontent and then you fill that one it will show your second and i want to fill data from my excel to that it will be adgroupInfo.2.adcontent
enter image description here
It same all DIV, SPAN ,But different Input ID
enter image description here
enter image description here
For this you will make use of a variable.
Dummy data:
Navigate to the element in the element list.
The click on the 3 dots menu to see the options.
Select Edit
Then scroll down to the enabled selector, this will in most cases be the id of the element on the web page.
replace the value with the name of the variable that will hold the control id value
Then in your loop assign the value of the UI element to the variable you used as the identifier.
Line 7 (red 2)
This should then fill the boxes as required.

Duplicate Worksheet but keep values only in google sheets

I have a google sheets doc linked to another sheets document via IMPORTRANGE.
I wish to have a duplicate which mantains Values only without the link data, since i am lookin to update the data and make like monthly reports based on that.
Is there a way to duplicate the sheets via script or another function or either break the links but mantain the values?
Make the copy and enable the IMPORTRANGE(s).
Then select the entire sheet by clicking the blank rectangle just above the left-hand row numbers and to the left of the top column letters. With the sheet selected, click Ctrl-C to copy to clipboard.
With the full-sheet selection still active, hit Ctrl-V for "Paste Special." Look for a clipboard icon to appear lower-right on the visible screen area. Click it and choose "Paste values only."

How to quickly create a hyperlink to a sheet

I have a contents page of all the sheets in the document.
All of the cells listed under 'Rounds' and 'Data Input' have the same name as the sheet they are linking to, as you can see in the screenshot.
I was wondering if there is a way to create a link for all of these cells automatically, instead of going through every single one.
Thanks for the help.
I was able to do this by recording a Macro. Here are the steps I did whilst recording.
Delete all contents in the cells.
Paste in the array formula #player0 made me, into the first cell under the 'Rounds' column.
Select all the cells in the column and click on 'Convert to Links'.
Set colour to blue and underline so it looks like a link.
Here's the finished macro.

Google Sheets custom sidebar

I have a very long google sheets document. I often have to go to a specific area of that document to input data. I want to have a sidebar with designated hyperlinks to areas in the document to minimize the time it takes to get to the area I need to edit. How can I create a sidebar that reads links from a hidden tab displaying all the links I want displayed in the sidebar?
most likely it's not possible as you imagine it. instead, take a look on hyperlink jumps... right-click the cell you want to jump in and select Get link to this cell:
then just paste it in your separate sheet or side column/frozen row
to make it nicer you can use HYPERLINK formula and assign some short alias

Resources