DynaPDF.ParseContent
--------------------

Runs the content parser.

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

MBS( "DynaPDF.ParseContent"; PDF; PageIndex ) 

**MBS**( **"DynaPDF.ParseContent";** /\* Runs the content parser. \*/  
**$PDF**; /\* The PDF reference returned from [DynaPDF.New](DynaPDFNew.md). \*/   
**$PageIndex**) /\* The page to check. Range is from one to [DynaPDF.GetPageCount](DynaPDFGetPageCount.md).e.g. 1 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| PDF | The PDF reference returned from [DynaPDF.New](DynaPDFNew.md). | $pdf |
| PageIndex | The page to check. Range is from one to [DynaPDF.GetPageCount](DynaPDFGetPageCount.md). | 1 |

### Result

Returns text or error.

### Description

Runs the content parser.  
Returns a list of text representations of the various PDF commands founds.  
  
Output shows entries like this:  
SaveGraphicState  
Rectangle X: 0.000000 Y: 0.000000 W: 842.000000 H: 595.000000  
ClipPath EvenOdd: 0 PathFillMode: 10  
SetFillColor IColorSpace: 0x843e34d0 ExtColorSpace: 6 NumComps: 1 Color\[0\]: 1.000000   
MulMatrix Matrix: 1.000000 0.000000 0.000000 -1.000000 0.000000 595.000000  
Rectangle X: 19.842520 Y: 19.637820 W: 240.944900 H: 555.690600  
SetFont FontType: 1 Embedded: 1 FontName: Cochin Style: 419430400, FontSize: 1.000000, Font: 0x86131e00  
ShowTextArray Count: 1 Width: 1.500000 Matrix: 13.000000 0.000000 0.000000 -13.000000 63.150010 237.000000 SourceAdvance\[0\]: 0.000000 SourceLength\[0\]: 3 SourceText\[0\]: SourceAdvance\[0\]: 0.000000 SourceLength\[0\]: 3 SourceText\[0\]: +49 KerningAdvance\[0\]: 0.000000 KerningLength\[0\]: 3 KerningWidth\[0\]: 1.500000 KerningText\[0\]: +49   
  
This function uses the parser interface in DynaPDF and needs a Pro license.  
  
If you have an open page, we close it automatically for you before doing the import.  
See also [ParseContent](https://www.monkeybreadsoftware.com/DynaPDF-Manual/ParseContent.shtml) function in DynaPDF manual.

### Examples

Parse content of page 6:

 MBS ( "DynaPDF.ParseContent"; $pdf ; 6 )  
### See also

- [DynaPDF.ErrLogMessage](DynaPDFErrLogMessage.md)
- [DynaPDF.ErrLogMessages](DynaPDFErrLogMessages.md)
- [DynaPDF.GetContent](DynaPDFGetContent.md)
- [DynaPDF.GetPageCount](DynaPDFGetPageCount.md)
- [DynaPDF.Initialize](DynaPDFInitialize.md)
- [DynaPDF.New](DynaPDFNew.md)
- [DynaPDF.Parser.Content](DynaPDFParserContent.md)
- [DynaPDF.SetContent](DynaPDFSetContent.md)
- [DynaPDF.SetRenderingIntent](DynaPDFSetRenderingIntent.md)

### Release notes

- **Version 13.2**
    - Fixed [DynaPDF.ParseContent](https://www.mbsplugins.eu/DynaPDFParseContent.shtml) to not complain about open page.
- **Version 10.2**
    - Fixed crash in [DynaPDF.ParseContent](https://www.mbsplugins.eu/DynaPDFParseContent.shtml) function.

### Blog Entries

- [MBS FileMaker Plugin, version 13.2pr1](https://www.mbsplugins.de/archive/2023-04-01/MBS_FileMaker_Plugin_version_1/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 10.2pr1](https://www.mbsplugins.de/archive/2020-04-01/MBS_FileMaker_Plugin_version_1/monkeybreadsoftware_blog_filemaker)
- [MBS Filemaker Plugin, version 4.0pr1](https://www.mbsplugins.de/archive/2014-01-03/MBS_Filemaker_Plugin_version_4/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 18th August 2014 , last changed 25th September 2024

  
[DynaPDF.PageStatistics](DynaPDFPageStatistics.md) - [DynaPDF.Parser.ChangeAltFont](DynaPDFParserChangeAltFont.md)

[HTML Version](DynaPDFParseContent.shtml)