Convert

PdfToMdConverter.Convert method (1 of 2)

Converts the loaded PDF document to Markdown (MD) and writes the result to the specified stream.

public void Convert(Stream outputStream, 
    Action<WordProcessingConvertOptions> convertOptionsAction = null)
parameterdescription
outputStreamThe stream where the converted MD will be written.
convertOptionsActionOptional delegate to configure MD-specific conversion options. Use WordProcessingConvertOptions to set options such as output format or password protection.

Remarks

For more details and examples, see the LowCode developer guide: https://docs.groupdocs.net/conversion/developer-guide/

Examples

// Stream-based conversion with convert options using (var converter = new PdfToMdConverter(“sample.pdf”)) using (var outputStream = new FileStream(“converted.md”, FileMode.Create)) { converter.Convert(outputStream, options => { options.Format = WordProcessingFileType.Md; }); }

See Also


PdfToMdConverter.Convert method (2 of 2)

Converts the loaded PDF document to Markdown (MD) and saves it to the specified file path.

public void Convert(string filePath, 
    Action<WordProcessingConvertOptions> convertOptionsAction = null)
parameterdescription
filePathThe output file path where the converted MD will be saved.
convertOptionsActionOptional delegate to configure MD-specific conversion options. Use WordProcessingConvertOptions to set options such as output format or password protection.

Remarks

For more details and examples, see the LowCode developer guide: https://docs.groupdocs.net/conversion/developer-guide/

Examples

// Basic conversion using (var converter = new PdfToMdConverter(“sample.pdf”)) { converter.Convert(“converted.md”); } // With convert options using (var converter = new PdfToMdConverter(“sample.pdf”)) { converter.Convert(“converted.md”, options => { options.Format = WordProcessingFileType.Md; }); }

See Also