Possible to create a URL/Hyperlink for new item (Automatically)?
We would like to create a URL/Hyperlink for new item automatically...in the attached example I had to 1) Manually go to row, 2) Select Properties, 3) Copy the Row Link, 4) Paste the Row Link in the field. We would like this to happen automatically, so far everything I have read says it is not possible.
Someone have a clever workaround? Any/all assistance is appreciated, thanks.
Answers
-
What is the intention of getting the Row URL? I'm sure this is possible using the publicly available API by getting the row ID, and then concatenating it to a URL for the sheet -- however, there may be some work arounds depending on why you need the row URL.
If you want to go the API route, here is a script I've made with Python which can do this function for you:
import smartsheet access_token = 'YOUR_ACCESS_TOKEN' smartsheet_client = smartsheet.Smartsheet(access_token) sheet_id = 'YOUR_SHEET_ID' sheet = smartsheet_client.Sheets.get_sheet(sheet_id) # RENAME "getRowId" WITH YOUR ROW COLUMN FOR PYTHON TO PASTE ROWID (replace this to your column name) columns = sheet.columns for column in columns: if column.title == "getRowId": column_id = column.id break # Append the row ID of each row to column_id column (getRowId) rows = sheet.rows for row in rows: row_id = row.id cell = smartsheet.models.Cell() cell.column_id = column_id cell.value = row_id updated_row = smartsheet.models.Row() updated_row.id = row.id updated_row.cells.append(cell) smartsheet_client.Sheets.update_rows(sheet_id, [updated_row])
With this python script, I was able to achieve the desired result here:
Where Base URL column is the formula
="https://app.smartsheet.com/sheets/SHEET_URL_HERE?rowId="
and where Full URL is just:
=[Base URL]@row + getRowId@row
You could also just entirely remove the Full URL column and change the base column to be:
="https://app.smartsheet.com/sheets/SHEET_URL_HERE?rowId=" + getRowId@row
Hope this helps!
Sincerely,
Jacob Stey
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 139 Industry Talk
- 472 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives