AnsweredAssumed Answered

running command line command from VBA

Question asked by Chris Pratt on Feb 22, 2018
Latest reply on Feb 22, 2018 by Ulf Stockburger

In a VBA macro I wish to run a string as a command line command. Can this be done? How is this done?

 

Separately, I want to set the read-only state of a file on disk. "SldWorks.IModelDoc2.SetReadOnlyState(True)" and "SldWorks.DocumentSpecification.ReadOnly = True" sets what SolidWorks thinks the read-only state is, not the file's actual read-only state on disk. However I can easily accomplish this with python, so I'm trying to run python code with input from a VBA macro. You could probably do this with C# or C++ but I'd prefer to do it in a familiar environment .

Outcomes