GetFromFile Method
- Namespace
TXTextControl.DocumentServer. PDF
- Package
TXTextControl.asTextControl. Core. SDK TXDocumentServer.from the private NuGet feed or Text Control Offline PackagesCore. dll
- Also in
TXTextControl.asTextControl. ASP. SDK TXDocumentServer.dll
Description
Returns an array of EmbeddedFile objects that represent all embedded files in the specified PDF document.
Syntax
public static EmbeddedFile[] GetFromFile(string fileName);Public Function GetFromFile(fileName As String) As EmbeddedFile()Parameters
| Parameter | Description |
|---|---|
| fileName | The complete file path of the PDF document. |
Return Value
Returns an array of EmbeddedFile objects.
Examples
The following example retrieves from file from the attachments.
TXTextControl.DocumentServer.PDF.EmbeddedFile[] results = TXTextControl.DocumentServer.PDF.Attachments.GetFromFile("document.docx");
foreach (TXTextControl.DocumentServer.PDF.EmbeddedFile embeddedFile in results)
{
Console.WriteLine(embeddedFile);
}Dim results As TXTextControl.DocumentServer.PDF.EmbeddedFile() = TXTextControl.DocumentServer.PDF.Attachments.GetFromFile("document.docx")
For Each embeddedFile As TXTextControl.DocumentServer.PDF.EmbeddedFile In results
Console.WriteLine(embeddedFile)
Next