I do not not think that that is the problem as I have done similar AppleScripts which work fine. I suggest to put the calculation result in a variable so you can check the syntax, especially where quotes and whitespaces are concerned. You can then also test the script outside of FileMaker to see if that runs ok.
Could it be that the resulting name requires quotes as it will be multiple words (I guess that there should be a whitespace in between first and last name although the calculation does not put one there), and as long as you have just either first or last name the resulting string is just one word?
Your quotation marks do not balance.
"tell application \"Finder\"" & ¶ & "do shell script \"python ~/Scripts/PDFMerge.py \"" & Students::First Name & Students::Last Name & ¶ & "end tell"
That doesn't work at all. Filemaker gives me a
"Expected end of line but found identifier" error -2741
I don't think it is Whitespace problems, if I create a variable, like $NameString or $$NameString, and do a display dialog, it looks right.
It is totally strange it will run fine with ONE of the fields, like first name, but not the second field.
Ok, it looks right. Does it execute correctly also from within AppleScript Editor?