| Components | All | New | MacOS | Windows | Linux | iOS | ||||
| Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old | |
DynaPDF.LoadSVGFile
Opens the specified SVG file from disk.
| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
| DynaPDF | 16.4 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
MBS( "DynaPDF.LoadSVGFile"; PDF; Path ) More
Parameters
| Parameter | Description | Example |
|---|---|---|
| The PDF reference returned from DynaPDF.New. | ||
| Path | The native file path for the SVG file. | "C:\test\image.svg" |
Result
Returns OK or error.
Description
Opens the specified SVG file from disk.SVG files are available in different flavors. Regular SVG files contain exactly one graphic but SVG files can also contain more than one graphic or symbol. Such symbol files contain no visible graphic if loaded without a symbol name.
In order to determine which kind of SVG file we have in memory, the function
DynaPDF.GetSVGSymbolCount must be called after the SVG file was loaded. If the return value is greater zero, the file contains multiple symbols. In such a case the desired symbol name must be passed to DynaPDF.InsertSVG, otherwise there is no visible output.
The symbol names that a SVG file contains can be accessed with DynaPDF.GetSVGSymbolName. The function accepts an index from 0 through DynaPDF.GetSVGSymbolCount -1.
Examples
Query symbol count for SVG file:
Let(
[
path = "/Users/cs/Desktop/EUworld.svg" ;
pdf = MBS( "DynaPDF.New" ) ;
r = MBS( "DynaPDF.LoadSVGFile" ; pdf; path ) ;
count = MBS( "DynaPDF.GetSVGSymbolCount" ; PDF ) ;
r = MBS( "DynaPDF.Release" ; pdf )
] ;
count
)
Example result: 1
[
path = "/Users/cs/Desktop/EUworld.svg" ;
pdf = MBS( "DynaPDF.New" ) ;
r = MBS( "DynaPDF.LoadSVGFile" ; pdf; path ) ;
count = MBS( "DynaPDF.GetSVGSymbolCount" ; PDF ) ;
r = MBS( "DynaPDF.Release" ; pdf )
] ;
count
)
Example result: 1
See also
- DynaPDF.GetSVGSize
- DynaPDF.GetSVGSizes
- DynaPDF.GetSVGSymbolCount
- DynaPDF.GetSVGSymbolName
- DynaPDF.GetSVGSymbolNames
- DynaPDF.InsertSVG
- DynaPDF.LoadSVG
- DynaPDF.New
- DynaPDF.Release
Release notes
- Version 16.4
- Added DynaPDF.LoadSVG, DynaPDF.LoadSVGFile and DynaPDF.InsertSVG functions.
Blog Entries
This function checks for a license.
Created 8th August 2026, last changed 9th August 2026
MarkDown version: DynaPDFLoadSVGFile.md