VBA Error 48 when calling some functions in macro

I'm trying to write an export macro, and using the function edge.GetStartVertex (and a lot of related functions) causes an Error 48 with no description. Googling has shown that its an issue with a dll somewhere, but I can't figure out what the issue is or even the affected dll. I have replicated the issue on some of my coworkers' machines, but some of them it works without issue.

 

Somewhat related, calling edge.EdgeInFaceSense crashes SolidWorks.