BCL easyConverter SDK HTML
easyConverter SDK Usermanual
PDF-to-HTML Programming API  |  Download Free Trial  |  Contact Us to Purchase

SymbolFontToUnicode Property

Determines whether to translate the Symbol font to Times New Roman Unicode.

This property is ignored when AbsolutePositioning is set to True.

bool SymbolFontToUnicode { set; }
Property SymbolFontToUnicode As Bool
def setSymbolFontToUnicode(self, newVal)
void setSymbolFontToUnicode(boolean newVal) throws PDF2HTMLException
function setSymbolFontToUnicode($newVal)
BCL_BOOL SymbolFontToUnicode;
Sub SymbolFontToUnicode(newVal As Bool)
beconvh.exe -symbolToUnicode [on|off]

Parameters

newVal

True - Translate the Symbol font to Times New Roman Unicode (Default)
False - Keep the Symbol font (not recommended in general)

Remark

Note that it is not recommended to use the Symbol font in HTML files, mainly because it is not portable. Only Microsoft Windows has the Symbol font, which means it may not be rendered correctly on other operating systems, smart phones and tablets. Most users are far better off with standard Unicode characters than with the proprietary Symbol character set.

Exception Handling

Please refer to the list of return exceptions.

Example Usage

using BCL.easyConverter.HTML;
...
PDF2HTML pdf2html = new PDF2HTML();
try
{
   pdf2html.SymbolFontToUnicode = true; // Translate symbol fonts to Unicode
   pdf2html.ConvertToHTML(@"c:\temp\input.pdf", @"c:\temp\output.html");
}
catch(PDF2HTMLException ex)
{
   Console.WriteLine(ex.Message);
}
finally
{
   pdf2html.Dispose();
}
Imports BCL.easyConverter.HTML
...
Dim pdf2html As New PDF2HTML()
Try
   pdf2html.SymbolFontToUnicode = True ' Translate symbol fonts to Unicode
   pdf2html.ConvertToHTML("c:\test\input.pdf", "c:\test\output.html")
Catch ex As PDF2HTMLException
   System.Console.WriteLine(ex.Message)
Finally
   pdf2html.Dispose()
End Try
import PDF2HTML
pdf2html = PDF2HTML.PDF2HTML()
try:
   pdf2html.setSymbolFontToUnicode(True) # Translate symbol fonts to Unicode
   pdf2html.ConvertToHTML("c:\\test\\input.pdf", "c:\\test\\output.html")
except PDF2HTML.PDF2HTMLException as ex:
   print(ex)
PDF2HTML pdf2html = new PDF2HTML();
try
{
   pdf2html.setSymbolFontToUnicode(true); // Translate symbol fonts to Unicode
   pdf2html.ConvertToHTML("c:\\temp\\input.pdf", "c:\\temp\\output.html", "", 0, -1);
}
catch(PDF2HTMLException e)
{
   System.out.println(e);
}
finally
{
   pdf2html.dispose();
}
<?php
require("PDF2HTML.php");
$pdf2html = new BCL\easyConverter\HTML\PDF2HTML();
try
{
   $pdf2html->setSymbolFontToUnicode(true); // Translate symbol fonts to Unicode
   $pdf2html->ConvertToHTML("c:\\test\\input.pdf", "c:\\test\\output.html");
}
catch(BCL\easyConverter\HTML\PDF2HTMLException $ex)
{
   echo $ex->getMessage(), "\n";
}
?>
#include <stdio.h>
#include <windows.h>
#include "easyConverterHTML.h"

int main()
{
   HMODULE hPdf2HtmlDll = LoadLibraryW(L"C:\\Program Files\\BCL Technologies\\easyConverter SDK 5\\Html\\easyConverterHTML.dll");
   if(!hPdf2HtmlDll)
   {
      printf("easyConverter could not be loaded.\n");
      return 1;
   }
   else
   {
      BclWdhrError error;
      BclPDF2HTML* pPdf2Html = CreatePDF2HTML(hPdf2HtmlDll);
      if(!pPdf2Html)
      {
         printf("easyConverter could not be initialized.\n");
         FreeLibrary(hPdf2HtmlDll);
         return 1;
      }
      pPdf2Html->SymbolFontToUnicode = BCL_TRUE; // Translate symbol fonts to Unicode
      error = pPdf2Html->ConvertToHTML(pPdf2Html, L"c:\\test\\input.pdf", L"c:\\test\\output.html", L"", 0, -1);
      if(error)
      {
         printf("Conversion failed with error %d.\n", error);
         FreeLibrary(hPdf2HtmlDll);
         return 1;
      }
      pPdf2Html->Dispose(pPdf2Html);
      FreeLibrary(hPdf2HtmlDll);
      return 0;
   }
}
oConverter = CreateObject("EasyConverter.PDF2HTML.5")
' Translate symbol fonts to Unicode
oConverter.SymbolFontToUnicode = True
Call oConverter.ConvertToHTML(inFileName, outFileName)
set beconvh="C:\Program Files\BCL Technologies\easyConverter SDK 5\Html\beconvh.exe"
REM Translate symbol fonts to Unicode
%beconvh% -symbolToUnicode -i "c:\test\input.pdf" -o "c:\test\output.html"