Excel Duplicate Substring Remover - Clean Repeated Text in Cells

Remove duplicate substrings from Excel cells with intelligent detection. Keep original formatting intact while eliminating redundant text using Aspose.Cells deduplication API.

Introduction: Remove Unwanted Characters with Precision

The Repeat Substring Cleaner API removes duplicate substrings within individual cells of an Excel range while preserving cell formatting, data validation, and other workbook structure. It processes each cell independently, keeping only the first occurrence of each duplicate substring.

Data Source Options

Field Type Required Description
workbook file Yes Excel workbook file (.xlsx, .xlsm)
range string Yes Target range to process (e.g., “A1:D100”, “Sheet1!A:D”)

Delimiter Options

Field Type Default Description
delimiters string "preset" Options: preset, custom , comma, semicolon, space, tab, line-break or Custom delimiter string (treats multiple chars as composite)
treatConsecutiveAsOne boolean false Collapse adjacent delimiters into single separator
ignoreCase boolean false Ignore case when comparing strings

RemoveDuplicateSubstrings API

API Endpoint

PUT http://api.aspose.cloud/v4.0/cells/content/remove/duplicate-substrings

The request parameters of removeCharacters API are

Parameter Name Type Path/Query String/HTTPBody Description
Spreadsheet File FormData The spreadsheet file to be processed. Supported formats include XLSX, XLS, ODS, CSV, etc.
delimiters String Query Specifies one or more delimiter characters used to split cell content into substrings for duplicate detection and removal. Multiple delimiters can be specified (e.g., ",;|").
treatConsecutiveDelimitersAsOne Boolean Query When set to true, consecutive delimiter characters are treated as a single separator. When false, each delimiter is processed individually.
caseSensitive Boolean Query When true, duplicate detection considers letter case (e.g., “Text” ≠ “text”). When false, case is ignored during duplicate comparison.
worksheet String Query (Optional) The name of the worksheet where duplicate substring removal will be applied. If omitted, the operation applies to the first worksheet.
range String Query (Optional) The cell range where duplicate substring removal will be applied (e.g., "A1:C10"). If omitted, the operation applies to all used cells in the specified worksheet.
outPath String Query (Optional) The cloud storage folder path where the processed workbook will be saved. If omitted, the file is saved in the source folder.
outStorageName String Query The name of the cloud storage where the output file will be stored.
region String Query (Optional) Sets the locale for text processing, which may affect delimiter interpretation and case sensitivity rules for certain languages (e.g., "en-US", "tr-TR").
password String Query (Optional) If the uploaded spreadsheet is password-protected, provide the password to open and process the file.

Response

{
File
}

Error Codes

  • 400 Bad Request: Invalid Aspose.Cells Cloud API URI.
  • 401 Unauthorized: Invalid access token. Or invalid client id and secret.
  • 404 Not Found: The spreadsheet file not accessible.
  • 500 Server Error: The spreadsheet has encountered an anomaly in obtaining calculation data.

Where should we use the Remove Duplicate Substrings API?

  • Data Cleaning & Standardization Scenarios: Clean up tags like "VIP,Premium,VIP,Gold" → `“VIP,Premium,Gold”
  • Technical & Operational Data: Clean log entries with repeated error codes, Remove duplicate bin/rack identifiers, and so on.
  • Content & Media Management: Deduplicate skill tags, Remove redundant certification entries.

Why should you use the Remove Duplicate Substrings API?

  • Automate Manual, Error-Prone Work: Eliminate tedious editing, Reduce human error, Scale instantly.
  • Preserve Data Integrity: Cell colors, fonts, borders, and conditional formatting remain unchanged, Drop-down lists and validation rules are preserved.
  • Flexible & Intelligent Processing: Delimiter-agnostic, Case-sensitive control, Header protection.
  • Seamless Integration: API-first design, Language agnostic, Returns clean file.
  • Developer-Friendly: Aspose.Cells Cloud offers SDK libraries in multiple languages, enabling quick development and comes with comprehensive documentation. Compared to building custom chart rendering solutions, this significantly reduces the development workload.
  • Cost-Effective: You can remove deduplicate characters without first uploading the workbook, which saves storage space and reduces costs.

OpenAPI Specification

The OpenAPI Specification defines a publicly accessible programming interface and lets you carry out REST interactions directly from a web browser.

Use Aspose.Cells Cloud SDKs

Using the SDK is the best way to accelerate development. The SDK handles the underlying details, allowing you to simply implement Remove characters for cells with minimal code. Please check out the GitHub repository for a complete list of Aspose.Cells Cloud SDKs.

The following code examples illustrate how to make calls to Aspose.Cells web services using various SDKs: