GroupDocsGists
10/24/2017 - 5:11 PM

SaveHTMLDocumentWithResourcesFolder.cs

// For complete examples and data files, please go to https://github.com/groupdocs-editor/GroupDocs.Editor-for-.NET

public static void SaveHTMLDocumentWithResourcesFolder()
        {
            // Obtain document stream
            Stream sourceStream = File.Open(Path.Combine(Common.sourcePath, Common.sourceFile), FileMode.Open, FileAccess.Read);
            using (InputHtmlDocument htmlDoc = EditorHandler.ToHtml(sourceStream))
            {
                // saving output html file.
                htmlDoc.Save(Path.Combine(Common.resultPath, Common.resultFile), Path.Combine(Common.resultPath, Common.resultResourcesFolder));
            }

            // close stream object to release file for other methods.
            sourceStream.Close();
        }