Skip to content

How to use range-update API with Microsoft Graph PHP SDK? #1649

@MarkDaleman

Description

@MarkDaleman

Hello humans of the earth,

I'm trying to figure out how to use the range-update API with the Microsoft Graph PHP SDK. I want to update the value of a specific cell in an Excel worksheet, but I’m not sure how to properly construct the request using the SDK.

What I've tried:

  • I attempted using WorkbookWorksheetItemRequestBuilder::rangeWithAddress() to target the cell, but there doesn’t seem to be a clear method to perform the PATCH with the updated value.
  • Using WorkbookRange directly is challenging since it lacks a setValues() method or any way to set cell content.
  • I tried using RequestInformation::setContentFromParsable(), but it throws a type error since it expects a Parsable object, not a simple array.

What I’m looking for:

  • A recommended way to use the SDK to perform the range-update without manually crafting the HTTP request.
  • If there’s no current method, is there a workaround using the SDK’s RequestAdapter that adheres to best practices?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions