How to read highlighted text? - c#

I made a windows app and i want that app to read the highlighted text but i am unable to solve this problem.
Can anyone suggest me how can it read highlighted text from anywhere. Example browser and notepad etc.
For simple strings I use
obj.SpeakAsync("Hello");
But How to read highlighted text?
I am so confused please tell me any method that solve this problem.

Related

C# Sendkeys with formatted text

So, I'm trying to send formatted text(RTF or HTML format) using SendKeys.Send, is this possible?
The only way that I found in order to do this: Set the text to clipboard and then paste it, but after doing some research I've found that this isn't a good practice and also I can't find a way to restore the clipboard after I paste the formatted text.
So I've solved this, when I was restoring the clipboard I didn't had any delays and because of that it wasn't working properly, now after I've added a small delay everything is working fine, in case someone have the same problem.

Printing from rich or normal textbox c#

Help me please with the easiest answer. I want to print text from my notepad and i don't know how. I've tried using print document, but my printer gives me empty sheet of paper. It working good normal.

Creating an HTML document out of RichTextBox in WPF

I am having issues creating an html document out of a RichTextBox. I am able to get all of the text out of the RichTextBox. This issue is when I go to get images that I pasted in by using Windows Snipping tool don't show up in the document. Is there a way to do this?
Perhaps you could give us a non-working example where the error occurs in order to help you. Anyway, you could also check this and this out.
Hope I helped!

how to search and highlight pdf's keyword programmatically

i've tried two different component to integrate pdf file in windows form application (c#).
the above mentionated component are PDFSharp and Sloppycode webBrowserEx.
Now, both of them work fine, but I'm not able to search and highlight programmatically full text defining by user through a textBox.
Can anyone give me some suggest to achieve my purpose?
Thanks in advance.
I found this answer to help me when I was working with PDFs. Not sure if you seen it yet but it may help you. I went with iTextSharp.
how to highlight a text or word in a pdf file using iTextsharp?
hope it helps.

ctrl-v image into richtextbox in sharepoint

I'm trying to ctrl-v an image into a RichTextBox in SharePoint using C#. So far, I've had no luck in successfully doing so. The image appears as a white space or as a broken image.
I know there is the option of using the clipboard or converting formats, but I'm not too sure how to do that (I've heard I need to convert clipboard image to a certain format before inserting it). Moreover, I want to check to see if anyone has tried to do something similar with success first.
Thanks.
Chris
This is not possible out of the box, you can however use RadEditor for sharepoint from telerik, it's free (the lite version) and allows for uploading of images while you are editing a page. Mind, you still need to upload the image first, then you can include it in the text using a url.
See this post for more info.

Categories