I everyone! I have an issue with my project app. I would like to remove an image which was previously added with a bookmark. In fact the user can take photos, automatically the app add the taken image to the words file looking for a specific bookmark.
Now if the user edit or remove this photo, the words document must be edited.
I looked on google and on this forum but no good answer for the moment.
Here is my actual code where I move to the bookmark and I add the image without removing the bm_photos bookmark because I use it again in order to insert another photos :
Document doc = new Document(FilePhoto);
DocumentBuilder builder = new DocumentBuilder(doc);
DocumentBuilder builder = new DocumentBuilder(doc);
Bookmark bm_photos = doc.Range.Bookmarks ["photos"];
builder.MoveToBookmark ("photos");
builder.StartBookmark("travaux_photos");
builder.MoveToBookmark ("travaux_photos");
builder.InsertImage (PhotoPath, 700, 394);
builder.InsertBreak(BreakType.ParagraphBreak);
builder.Writeln("");
builder.MoveToBookmark ("photos");
builder.StartBookmark("travaux_photos");
builder.MoveToBookmark ("travaux_photos");
builder.InsertImage (PhotoPath, 700, 394);
builder.InsertBreak(BreakType.ParagraphBreak);
builder.Writeln("");
doc.Save(FilePhoto);