I was able to figure out the problem. Apparently with Sage 100 ERP 2015 they have updated the PVXScript.DLL. For some reason, on the workstation where the script was failing, they had an older and smaller PVXScript.DLL in the Sage\Common Components folder. I copied the newer, larger PVXScript.DLL from the home folder to the Common Components folder and registered it there. Now the PVXScript works.