Error 5262: "Unable to create the requested cell link(s). The source data is no longer accessible."

Hi,

I'm getting this error message when attempting to create a link from a cell in another sheet (through creating a cell, a row, and then update_rows method). Has anyone seen this error? I'm reading a discussion on another thread that this error is related to some issue with profile data (?), but I can create this link manually, i.e. with Smartsheet interface...

Many thanks in advance for any help!

Tomasz

Answers

  • Genevieve P.
    Genevieve P. Employee Admin

    Hi@tkaczoro

    If you're able to take the action in the UI, you should be able to take that action using the API, you're correct.

    Is it possible that the row you're referencing to update no longer exists? (e.g. the row ID is incorrect). Can you confirm the SDK version that you're using?

    This may be best to troubleshootwith Support directlyso you can share private information (such as screen captures and code examples).

    Cheers,

    Genevieve

  • tkaczoro
    tkaczoro
    edited 04/04/23

    Hi@Genevieve P.,

    Thank you for responding. No, it is not possible that the rows referenced (from both sheet A and sheet B) do not exist. I can print to console contents of those rows during execution of the code. Python SDK version is 2.177.1.

    I reached out to Support yesterday, currently awaiting their response...

    Best regards,

    Tomasz

  • Genevieve P.
    Genevieve P. Employee Admin

    Hi@tkaczoro

    Thanks for clarifying! Would you be able to test using the currentPython SDK version 3.0.0to see if this resolves the error?

    Cheers,

    Genevieve

  • tkaczoro
    tkaczoro
    edited 04/05/23

    Hi@Genevieve P.,

    我测试使用电流Python SDK version 3.0.0and unfortunately it did not resolve the problem.

    Here is the essential part of the code , maybe it can help in troubleshooting:

    row = Row() row._id_ = Number(sheetA_row_id) cells = TypedList(Cell) cell = Cell() explicitnull = ExplicitNull() cell._value = explicitnull cell._column_id = Number(A_column_id) celllink = CellLink() celllink._column_id = Number(B_column_id) celllink._row_id = Number(sheetB_row_id) celllink._sheet_id = Number(sheetB_id) _celllink = TypedObject(CellLink) _celllink.value = celllink cell._link_in_from_cell = _celllink cells.insert(0, cell) row._cells = cells row_update = smartsheet.sheets.Sheets.update_rows(sheets, sheetA_id, row)

    Thank you,

    Tomasz

  • Genevieve P.
    Genevieve P. Employee Admin
    edited 04/14/23

    Hi@tkaczoro

    Thanks for testing! Can you clarify a little more in regards to the sheet you're updating?

    What is the column type that you're adding the cell-link into, and are you the owner of both sheets?

    Are you able to use the same code (but on a different sheet) successfully?

    你是using Project Settings on this sheet at all?

    It would be helpful to see a screen capture of your sheet; I'd like to recreate your set-up.

    Thanks!

    Genevieve

  • Hi@Genevieve P.,

    请参阅附加表的截图。肌萎缩性侧索硬化症o, here is the full code (I re-wrote it for clarity and to align with popular style/format):

    import smartsheet.sheets from smartsheet.models import Row, Cell, CellLink, ExplicitNull smart = smartsheet.Smartsheet(access_token='xxxxxxxxxxxxxxxxxxxxxxxxxxxx') sheets = smartsheet.sheets.Sheets(smart) sheetA_id = 4349218560206724 sheetA_row_id = 1839828046440324 sheetA_column_id = 7140800557016964 sheetB_id = 412818613790596 sheetB_row_id = 3312344608925572 sheetB_column_id = 360134934849412 row = Row() row.id = sheetA_row_id cell = Cell() cell.value = ExplicitNull() cell.column_id = sheetA_column_id celllink = CellLink() celllink.column_id = sheetB_column_id celllink.row_id = sheetB_row_id celllink.sheet_id = sheetB_id cell.link_in_from_cell = celllink row.cells.append(cell) row_update = smartsheet.sheets.Sheets.update_rows(sheets, sheetA_id, row)

    I'm currently the owner of both sheets. The columns are Text/Number type (I also tested Date columns), the cells that are to be linked are selected in the screenshots.

    I have not tried the code on completely different sheets, but I also tried admin(sheetA)/owner(sheetB) and when both sheets are in the same workspace.

    I have not tried changing anything in Project Settings. Is there anything to try there?

    Thank you!


  • Genevieve P.
    Genevieve P. Employee Admin

    Hi@tkaczoro

    This is all really helpful information - I can't replicate the error you're getting. The Project Settings question would be in relation to what column you're putting the link into, but from your images I can see you're using the Comments column, which should be fine.

    The last thing to test is to use two completely new, different sheets (changing the Sheet Ids, the Column Ids, and the Row Ids). This will determine if it's an issue with theses two specific sheets or with the API.

    If performing this action works fine on new sheets, please follow-up with Support letting them know of your tests along with the two sheet IDs of the ones that aren't working for you.

    I hope you have a good weekend!

    Genevieve

  • Hi@Genevieve P.,

    Great suggestion. I made this test - created two new sheets A and B and attempted to link some cells with my code. It worked!

    So it looks like the problem is specific to my sheets I'm trying to link. I will let Support know about this finding.

    Thank you very much for all your help! Wish you a nice weekend too!

    Tomasz

  • Genevieve P.
    Genevieve P. Employee Admin

    I'm glad you were able to get it working on new sheets! Thanks for following up.

  • Hi@Genevieve P.,

    After a long time testing different scenarios I was finally able to find the root cause. It was a typo in my code that gave row id of sheet A when it was supposed to be the value from sheet B.

    Thank you very much for your help with this. I will make sure next time to check the code multiple times before posting the issue.

    Best regards,

    Tomasz

  • Genevieve P.
    Genevieve P. Employee Admin

    Hi@tkaczoro

    I'm so glad to hear that you were able to identify the issue and get this working again!

You cannot sent an update request via API to text.<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":320,"name":"API & Developers","url":"https:\/\/community.smartsheet.com\/categories\/api-developers","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":1}],"tags":[{"tagID":227,"urlcode":"api-and-developers","name":"API and Developers"}]},{"discussionID":108829,"type":"question","name":"Power automate question (multi-contact list)","excerpt":"I'm using power automate to wire up some info into smartsheets. I have everything working so far but multi contact list and multi pick list. The contact list error I get is this: The value \"John smith\" could not be saved in column \"Assignment\". This column is restricted to MULTI_CONTACT_LIST values only. The name is…","snippet":"I'm using power automate to wire up some info into smartsheets. I have everything working so far but multi contact list and multi pick list. The contact list error I get is this:…","categoryID":320,"dateInserted":"2023-08-10T23:21:44+00:00","dateUpdated":"2023-08-11T08:46:38+00:00","dateLastComment":"2023-08-17T13:42:41+00:00","insertUserID":164958,"insertUser":{"userID":164958,"name":"jtadhs","title":"Title","url":"https:\/\/community.smartsheet.com\/profile\/jtadhs","photoUrl":"https:\/\/lh3.googleusercontent.com\/a\/AAcHTtfNpbIYWnLk6ZczJ1ClRDc4ET2YJ_HxgNiq2jl7URt0RjU=s96-c","dateLastActive":"2023-08-16T23:05:43+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":91566,"lastUserID":86866,"lastUser":{"userID":86866,"name":"Jeff Reisman","title":"","url":"https:\/\/community.smartsheet.com\/profile\/Jeff%20Reisman","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/userpics\/3V8W2AM105QE\/nIDXI4I7VDS7W.JPG","dateLastActive":"2023-08-18T19:31:15+00:00","banned":0,"punished":0,"private":false,"label":"✭✭✭✭✭✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":7,"countViews":118,"score":null,"hot":3383993665,"url":"https:\/\/community.smartsheet.com\/discussion\/108829\/power-automate-question-multi-contact-list","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/108829\/power-automate-question-multi-contact-list","format":"Rich","lastPost":{"discussionID":108829,"commentID":391128,"name":"Re: Power automate question (multi-contact list)","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/391128#Comment_391128","dateInserted":"2023-08-17T13:42:41+00:00","insertUserID":86866,"insertUser":{"userID":86866,"name":"Jeff Reisman","title":"","url":"https:\/\/community.smartsheet.com\/profile\/Jeff%20Reisman","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/userpics\/3V8W2AM105QE\/nIDXI4I7VDS7W.JPG","dateLastActive":"2023-08-18T19:31:15+00:00","banned":0,"punished":0,"private":false,"label":"✭✭✭✭✭✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Get Help","url":"https:\/\/community.smartsheet.com\/categories\/get-help"},{"name":"API & Developers","url":"https:\/\/community.smartsheet.com\/categories\/api-developers"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-08-15T22:16:09+00:00","dateAnswered":"2023-08-15T13:47:37+00:00","acceptedAnswers":[{"commentID":390662,"body":"
\n \n https:\/\/community.smartsheet.com\/discussion\/comment\/390588#Comment_390588\n <\/a>\n<\/div>\n

Is your Multi contact list column restricted to only values that are in the contact list for the sheet? If so, you might want to turn that off.<\/p>

Also make sure the column isn't locked.<\/p>

Also add a \"level\" parameter to the API call with value of 2, that should enable multi picklist and multi-contact list functions.<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":320,"name":"API & Developers","url":"https:\/\/community.smartsheet.com\/categories\/api-developers","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]},{"discussionID":108731,"type":"question","name":"API export to excel to include the rowpermalink","excerpt":"trying to include the rowpermalink in my sheet export according to the API doc the ?include=rowpermalink in the URL should do it however it does not show in the row with all the other data from the sheet. any help would be greatly apprecitated. $URL =…","snippet":"trying to include the rowpermalink in my sheet export according to the API doc the ?include=rowpermalink in the URL should do it however it does not show in the row with all the…","categoryID":320,"dateInserted":"2023-08-09T14:56:39+00:00","dateUpdated":null,"dateLastComment":"2023-08-11T17:42:09+00:00","insertUserID":164847,"insertUser":{"userID":164847,"name":"palefty","url":"https:\/\/community.smartsheet.com\/profile\/palefty","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-08-11T17:41:17+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":null,"lastUserID":164847,"lastUser":{"userID":164847,"name":"palefty","url":"https:\/\/community.smartsheet.com\/profile\/palefty","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-08-11T17:41:17+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":2,"countViews":90,"score":null,"hot":3383369928,"url":"https:\/\/community.smartsheet.com\/discussion\/108731\/api-export-to-excel-to-include-the-rowpermalink","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/108731\/api-export-to-excel-to-include-the-rowpermalink","format":"Rich","tagIDs":[227],"lastPost":{"discussionID":108731,"commentID":390267,"name":"Re: API export to excel to include the rowpermalink","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/390267#Comment_390267","dateInserted":"2023-08-11T17:42:09+00:00","insertUserID":164847,"insertUser":{"userID":164847,"name":"palefty","url":"https:\/\/community.smartsheet.com\/profile\/palefty","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-08-11T17:41:17+00:00","banned":0,"punished":0,"private":false,"label":"✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Get Help","url":"https:\/\/community.smartsheet.com\/categories\/get-help"},{"name":"API & Developers","url":"https:\/\/community.smartsheet.com\/categories\/api-developers"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-08-11T17:42:18+00:00","dateAnswered":"2023-08-10T03:06:28+00:00","acceptedAnswers":[{"commentID":389950,"body":"

Hi @palefty<\/a> <\/p>

The Smartsheet API does not possess a native method to directly fetch or incorporate clickable row permalinks when you export a sheet to an Excel file. So, users need more intuitive, clickable links within their exported Excel sheets.<\/p>

To address this, I have implemented a workaround:<\/p>

(I used Smartsheet SDK to implement the workaround)<\/p>

\n \n https:\/\/gist.github.com\/jmyzk\/5cc4dfbbf79b010d374f0b5ad3fa0a4b\n <\/a>\n<\/div>


<\/p>

Fetching Permalinks:<\/strong> The code interacts with the Smartsheet API to retrieve each row's permalink values.<\/p>

Incorporating into the sheet:<\/strong> These permalink values are then populated into a designated column. When you export the sheet as an Excel file, you'll notice a column filled with URLs corresponding to the permalinks for each row in Smartsheet.<\/p>

\n
\n \n \"export<\/img><\/a>\n <\/div>\n<\/div>\n
\n \n https:\/\/app.smartsheet.com\/b\/publish?EQBCT=adda95b9ed0d49f192faa76e1535bc47\n <\/a>\n<\/div>

Making the Links Clickable:<\/strong> As a final step, to enhance user experience and ease of access, the code processes the Excel file to convert these plain URL texts into clickable hyperlinks. Thus, when users click these links in the Excel sheet, they're directed to the appropriate Smartsheet row online.<\/p>

With the implemented code, users can easily navigate to Smartsheet rows directly from their Excel sheets.<\/p>

\n
\n \n \"expoerted<\/img><\/a>\n <\/div>\n<\/div>\n


<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":320,"name":"API & Developers","url":"https:\/\/community.smartsheet.com\/categories\/api-developers","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":227,"urlcode":"api-and-developers","name":"API and Developers"}]}],"initialPaging":{"nextURL":"https:\/\/community.smartsheet.com\/api\/v2\/discussions?page=2&categoryID=320&includeChildCategories=1&type%5B0%5D=Question&excludeHiddenCategories=1&sort=-hot&limit=3&expand%5B0%5D=all&expand%5B1%5D=-body&expand%5B2%5D=insertUser&expand%5B3%5D=lastUser&status=accepted","prevURL":null,"currentPage":1,"total":213,"limit":3},"title":"Trending in API & Developers","subtitle":null,"description":null,"noCheckboxes":true,"containerOptions":[],"discussionOptions":[]}">

Trending in API & Developers