--- title: "Set-VolumeRange" slug: "scripting-set-volumerange" updated: 2025-07-15T19:10:56Z published: 2025-07-15T19:10:56Z canonical: "help.agilityblue.com/scripting-set-volumerange" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.agilityblue.com/llms.txt > Use this file to discover all available pages before exploring further. # Set-VolumeRange ## Summary Updates an existing volume range. ```powershell Set-VolumeRange    -Entry    -IncludeVolume ``` Returns a [volume range](https://apidocs.agilityblue.com/#be5f5383-f972-44cf-b541-17b74e79bb16) object. ## Parameters | Parameter | Type | Required? | Notes | | --- | --- | --- | --- | | Entry | [Volume range](https://apidocs.agilityblue.com/#be5f5383-f972-44cf-b541-17b74e79bb16) object | Yes | | | IncludeVolume | Switch | No, Defaults to `false` | Adds the parent `Volume` property to the output. | ## Examples ### Update an existing volume range ```powershell # Update an existing volume range # A common flow for updating existing data is to first retrieve the data using the GET # command, update specific fields, and then provide the modified data back using the SET command. $entry = Get-VolumeRange -Id 22 # Update the beg/end no fields: $entry.BegNo = "B000001" $entry.EndNo = "B999999" # Save the modified volume range $data = Set-VolumeRange -Entry $entry # Output some information to help indicate that the volume range was updated Write-Output "Volume range $($data.VolumeRangeId) ($($data.BegNo) - $($data.EndNo)) was updated on volume $($data.VolumeId)" # For debug purposes, convert the data to output as JSON so we can see all the fields Write-Output "" Write-Output "JSON Results:" $jsonOutput = $data | ConvertTo-Json -Depth 10 # Output the data Write-Output $jsonOutput ``` Execution results: ```plaintext Volume range 22 (B000001 - B999999) was updated on volume 10 JSON Results: {  "VolumeRangeId": 22,  "VolumeId": 10,  "BegNo": "B000001",  "EndNo": "B999999",  "CreatedByFullName": "Max Miller",  "CreatedById": "510e109b-6ff5-4442-9670-cd5e3cd82a7a",  "CreatedOn": "2025-07-15T19:01:59.3193846+00:00",  "CreatedBy": null,  "LastUpdatedByFullName": "Max Miller",  "LastUpdatedById": "510e109b-6ff5-4442-9670-cd5e3cd82a7a",  "LastUpdatedOn": "2025-07-15T19:09:22.5224673+00:00",  "LastUpdatedBy": null,  "Volume": null } ```