Hi,
Wife works with large PDF's and constantly has to either copy and paste from a pdf to a word doc or has to manually type them out. All she needs is the title and the page it appears on, this is part of showing insurance T&C's in a cover letter.
I was hoping it would be easier for her to select the title, hit a key combo, AHK grabs that selected text and the page it's on and either concatenates it to a text doc without switching active program or saves it to memory until the user hits paste/ctrl+v.
Anyone know of a script that does this or any that would allow me to write something to do this?
I could attempt it in Python but AHK seems far more suited to doing this.
Thanks
PDF copying text/page number question
Re: PDF copying text/page number question
Easiest way is for her to run script below (no need for com), highlight what she needs and hit Q
Esc key exits the script
It will write what she highlighted and page number to a txt file in the directory of the script, or if you want change it
should save her time
Esc key exits the script
It will write what she highlighted and page number to a txt file in the directory of the script, or if you want change it
should save her time
Code: Select all
q::
send, ^c
ClipWait
ControlGetText, readerp, Edit2, A
; msgbox, Page Title %clipboard% Page Number %readerp% ;if you want to test
FileAppend,Page Title %clipboard% Page Number %readerp%`n, adobeproj.txt
return
esc::ExitApp
Re: PDF copying text/page number question
Excellent, thanks, I'll give this a try later this evening and see if it'll work for her!
-
- Posts: 2
- Joined: 26 Jul 2018, 12:38
Re: PDF copying text/page number question
Staff, taking advantage of this post I ask your help if it is possible
I'm trying to make a code that searches and finds a word in a pdf and in the sequence copies a text just below the localized word:
Here's the code I'm trying to make work:
LarguraTela := 1280
AlturaTela := 1024
PixelSearch, X, Y, 0, 0, %LarguraTela%, %AlturaTela%, 0xD8C199, 0, fast
if ErrorLevel
{
Msgbox Not Find
}
else
{
newX := X + 50
newY := Y + 50
MouseClick, left, %newX%, %newY%
}
Can you guide me?
I'm trying to make a code that searches and finds a word in a pdf and in the sequence copies a text just below the localized word:
Here's the code I'm trying to make work:
LarguraTela := 1280
AlturaTela := 1024
PixelSearch, X, Y, 0, 0, %LarguraTela%, %AlturaTela%, 0xD8C199, 0, fast
if ErrorLevel
{
Msgbox Not Find
}
else
{
newX := X + 50
newY := Y + 50
MouseClick, left, %newX%, %newY%
}
Can you guide me?