File tree Expand file tree Collapse file tree 2 files changed +6
-8
lines changed
Markdown-to-Word-conversion/Modify-image-size/Modify-image-size Expand file tree Collapse file tree 2 files changed +6
-8
lines changed Original file line number Diff line number Diff line change 66![ Road] ( Road-550.png )
77
88
9- ** Product No:** BK\- M68B\- 38
109
1110** Size:** 38
1211
1817![ Mountain] ( https://www.syncfusion.com/downloads/support/directtrac/general/Mountain-300-989274178.png )
1918
2019
21- ** Product No:** BK\- M47B\- 38
2220
2321** Size:** 35
2422
Original file line number Diff line number Diff line change 22using Syncfusion . DocIO ;
33using System . Net ;
44
5- // Create a Word document instance.
6- using ( WordDocument document = new WordDocument ( ) )
5+ using ( FileStream inputFileStream = new FileStream ( Path . GetFullPath ( @"Data/Input.md" ) , FileMode . Open , FileAccess . Read ) )
76{
8- // Hook the event to customize the image while importing Markdown.
9- document . MdImportSettings . ImageNodeVisited += MdImportSettings_ImageNodeVisited ;
10- using ( FileStream inputFileStream = new FileStream ( Path . GetFullPath ( @"Data/Input.md" ) , FileMode . Open , FileAccess . Read ) )
7+ // Create a Word document instance.
8+ using ( WordDocument document = new WordDocument ( ) )
119 {
10+ // Hook the event to customize the image while importing Markdown.
11+ document . MdImportSettings . ImageNodeVisited += MdImportSettings_ImageNodeVisited ;
1212 // Open the input Markdown file.
1313 document . Open ( inputFileStream , FormatType . Markdown ) ;
14- // Find all images with the alternative text "Mountain" and resize them .
14+ // Find a picture by its alternative text and resize it .
1515 WPicture picture = document . FindItemByProperty ( EntityType . Picture , "AlternativeText" , "Mountain" ) as WPicture ;
1616 picture . Height = 250 ;
1717 picture . Width = 250 ;
You can’t perform that action at this time.
0 commit comments