DynaPDF.RenameSpotColor
-----------------------

Renames a spot color.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [DynaPDF](component_DynaPDF.md) | [7.2](newinversion72.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "DynaPDF.RenameSpotColor"; PDF; Colorant { ; NewName } ) 

**MBS**( **"DynaPDF.RenameSpotColor";** /\* Renames a spot color. \*/  
**$PDF**; /\* The PDF reference returned from [DynaPDF.New](DynaPDFNew.md). \*/   
**$Colorant**; /\* Colorant name to change.e.g. "PANTONE 376 C" \*/   
**$NewName**) /\* Optional; New name or empty.e.g. "Cyan" \*/ 

### Parameters

| Parameter | Description | Example | Flags |
|---|---|---|---|
| PDF | The PDF reference returned from [DynaPDF.New](DynaPDFNew.md). | $pdf |  |
| Colorant | Colorant name to change. | "PANTONE 376 C" |  |
| NewName | New name or empty. | "Cyan" | Optional |

### Result

Returns number or error.

### Description

Renames a spot color.  
Renames the spot color Colorant to NewName in all Separation, DeviceN, and NChannel color spaces in which the colorant can be found. If the parameter NewName is set to empty, the function renames the colorant to the special value None which produces no visible output.   
The representation of the colorant in the alternate color space is left unchanged, also if the colorant is set to the special value None or All.  
The function returns the number of color spaces in which the colorant has been changed. If the function fails the return value is the error message.  
See also [RenameSpotColor](https://www.monkeybreadsoftware.com/DynaPDF-Manual/RenameSpotColor.shtml) function in DynaPDF manual.

### See also

- [DynaPDF.New](DynaPDFNew.md)

### Release notes

- **Version 7.2**
    - Added [DynaPDF.ChangeSeparationColor](http://www.mbsplugins.eu/DynaPDFChangeSeparationColor.shtml) and [DynaPDF.RenameSpotColor](http://www.mbsplugins.eu/DynaPDFRenameSpotColor.shtml).

### Example Databases

- [DynaPDF/Change Separation Colorant](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/DynaPDF/Change%20Separation%20Colorant.shtml#2ScriptAnchor_)

### Blog Entries

- [MBS FileMaker Plugin, version 7.2pr1](https://www.mbsplugins.de/archive/2017-04-03/MBS_FileMaker_Plugin_version_7/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 22nd March 2017 , last changed 22nd March 2017

  
[DynaPDF.ReleaseAll](DynaPDFReleaseAll.md) - [DynaPDF.RenderJob](DynaPDFRenderJob.md)

[HTML Version](DynaPDFRenameSpotColor.shtml)