AnsweredAssumed Answered

How to import step file in solidworks using c#.net

Question asked by Suresh Vijayan on Apr 10, 2016
Latest reply on Apr 14, 2016 by Suresh Vijayan

Hi,

i am facing problem in importing the step file in solidworks using c#.net.

 

i used the api help, with that reference i used loadfile2 option to import step file.

but it showing error kindly help me to solve this problem

thanks in advance.

below i attached by code.

stepfiles = path of the stepfile

 

public string ConvertingStpFile(string strStpFilePath)

 

        {

 

 

            //=========================================Gets the Files From the folder=====================================

 

            SwConnect();

 

            string[] stpFilesFolder = Directory.GetFiles(strStpFilePath);          

 

 

            foreach (string StepFiles in stpFilesFolder)

            {

                isldWorks.LoadFile2(StepFiles, "r");

            }

 

return strStpFilePath;

 

}

Outcomes