Hi
The script is suppose to rename a generic pdf generated by my scanner to a specific name pulled from a FileMaker DB. I’ve got it working up to the line changing the name. If I plug in a any quote text it work fine but if I try to use the string on the clipboard it will fail to change the file name. Looking at the Events/Results the the proper string is there but the file name does not change. Here is the the part of the script that in question
tell application "FileMaker Pro"
activate
tell database "MedicalReciepts2011.fp7"
do script "Get PDF Name" -- gets value from field and puts it on the clipboard
end tell
end tell
set theFolder to "Macintosh HD:Users:alanmcw:Documents:Personal:Privite:11 Med Files:PDFs:"
tell application "Finder" to set theFileName to (the clipboard) as string --does not work
--tell application "Finder" to set theFileName to "test" as string --does work
tell application "Finder"
set the name of the first file of the folder theFolder to theFileName & ".pdf"
end tell
Here is the Event/Reply using the clipboard…
If you switch lines 10 & 11 it works.
I’m sure I’m missing some thing really obvious but I’m just not seeing it.
Any help will be much appreciated
cheers
al