I'm working with an API that has a COM-based interface. I've been using the win32ole module to instantiate the API, but one of the API functions requires a null value, and win32ole complains when a null argument is passed. I found this workaround, but it just replaces a null value with an object. This allows me to pass null as an argument to the function call without win32ole complaining, but the function still fails because it requires a null value, which is now being replaced by an object in the workaround.
How can I pass a null argument to this API function?
api.Order_Import('import.xml', 'import.xsd', 0, false, '', '', null)
The first thing I tried was leaving off the last argument. This makes win32ole happy, but still causes the function to fail with the error message Parameter 'loOptParam' must be null.
Is there another module I can use besides win32ole for working with COM objects in node? My research didn't turn anything up.