Hi
How do I extract/copy-to-clipboard text from PDF in Rich Text format ? I have read the IPXV_TextSelection Interface but am unable to find out how exactly to access the interface.
Regards
Floater
How to Copy Rich text to clip board
Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan
Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.
When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
- Lzcat - Tracker Supp
- Site Admin
- Posts: 677
- Joined: Thu Jun 28, 2007 8:42 am
Re: How to Copy Rich text to clip board
Hi floater.
If you need just copy to clipborad please call CopyAsRich fucntion, and all selected text will be copied to clipboard.
If you need to inspect or get selection other way code will be much more complicated (at least for now).
HTH.
If you need just copy to clipborad please call CopyAsRich fucntion, and all selected text will be copied to clipboard.
If you need to inspect or get selection other way code will be much more complicated (at least for now).
HTH.
Victor
Tracker Software
Project manager
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Tracker Software
Project manager
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 3
- Joined: Mon Sep 21, 2015 6:16 am
Re: How to Copy Rich text to clip board
Here's the sample which you can experiment with:
Code: Select all
PDFXEdit.IPXV_Document doc = pdfCtl.Doc;
if (doc == null)
return;
int cmdID = pdfCtl.Inst.Str2ID("selection.text");
PDFXEdit.IPXV_TextSelection textSel = (PDFXEdit.IPXV_TextSelection)doc.GetSel(cmdID);
if (null != textSel)
{
textSel.CopyAsRich();
}
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ