Hi Everyone,
I need some help with the following macro. When I run it, it fails when GetItem("ManufacturingProgram.1") is being executed. Any help is greatly appreciated.
Thanks,
Kalyan
Language="VBSCRIPT"
Sub CATMain()
Dim processDocument1 As Document
Set processDocument1 = CATIA.ActiveDocument
Dim manufacturingAPTGenerator1 As CATBaseDispatch
Set manufacturingAPTGenerator1 = processDocument1.GetItem("Manufacturing Program.1")
manufacturingAPTGenerator1.InitFileGenerator "APT", "D:\Users\kal\Misc\CATIA\Process1_Manufacturing_Program_2.ap tsource", manufacturingGeneratorData1
manufacturingAPTGenerator1.RunFileGenerator manufacturingGeneratorData1
manufacturingGeneratorData1.ResetAllModalValues
End Sub
I need some help with the following macro. When I run it, it fails when GetItem("ManufacturingProgram.1") is being executed. Any help is greatly appreciated.
Thanks,
Kalyan
Language="VBSCRIPT"
Sub CATMain()
Dim processDocument1 As Document
Set processDocument1 = CATIA.ActiveDocument
Dim manufacturingAPTGenerator1 As CATBaseDispatch
Set manufacturingAPTGenerator1 = processDocument1.GetItem("Manufacturing Program.1")
manufacturingAPTGenerator1.InitFileGenerator "APT", "D:\Users\kal\Misc\CATIA\Process1_Manufacturing_Program_2.ap tsource", manufacturingGeneratorData1
manufacturingAPTGenerator1.RunFileGenerator manufacturingGeneratorData1
manufacturingGeneratorData1.ResetAllModalValues
End Sub