0

I am working on a UWP app in which am working RichEditBox with inline images. Here I want do some operations based on which image the user tapped. I am not able to find any events to handle when the inline image is tapped. Tapped and PointerPressed events not triggering for RichEditBox. Clearly what i want is a event in which i can get which inline image is clicked or tapped.

I am getting the image file from image library by file picker as StorageFile.

Here is the code through which I insert image to RichEditBox

 using (var imageStream = await imageFile.OpenAsync(FileAccessMode.Read))
            {
                var bitmapImage = new BitmapImage();
                bitmapImage.SetSource(imageStream);

                richEditBox.Document.Selection.InsertImage((int)bitmapImage.PixelWidth, (int)bitmapImage.PixelHeight, 0, Windows.UI.Text.VerticalCharacterAlignment.Baseline, "ImageName", imageStream);
                imagePosition.Add(imageFilesList[0]);
            };

Can anyone help me to short this out?

Thank you. Noorul.

Noorul
  • 873
  • 2
  • 9
  • 26

0 Answers0