Replying to self with progress, and maybe someone can help.
Drop the single page pdf onto the script; it calls an automator which converts the pdf to plaintext; applescript then reads the txt file for the data I want; last step is to rename the original file with the string that I want (a name).
I'm getting error -10006, can't rename. Below is the script and a screenshot of the automator.
on openfileList
tell application "Finder"
--set thePDFfile to (choose file)
repeat with thePDFfile in fileList
set theInfo to info forthePDFfile
set theFile to name of theInfo
set qtdstartpath to quoted form of (POSIX path of thePDFfile)
set workflowpath to "/Users/Galen/PDFextract/NoInput.workflow"
set qtdworkflowpath to quoted form of (POSIX path of workflowpath)
set command to "/usr/bin/automator -i " & qtdstartpath & " " & qtdworkflowpath
set output to do shell scriptcommand
--do shell script "automator /Users/Galen/PDFextract/NoInput.workflow"
set AppleScript'stext item delimiters to "
set thetext to text items of (read "/Users/Galen/Desktop/ExtractOutput.txt")
set studentName to item 2 of thetext
set AppleScript'stext item delimiters to " "
set thetext to text items of studentName
set lastName to item 2 of thetext
set firstName to item 3 of thetext
set lastFirst to (lastName & " " & firstName)
--return lastFirst
set AppleScript'stext item delimiters to ""
set the name of theFile to ((lastFirst as text) & ".pdf")
end repeat
end tell
end open