Sunday, March 29, 2015

How to create a parameter CATIA macro

This CATIA CATScript macro creates a new parameter in a CATPart file.

'####################################
Sub CATMain()
'set the active document (must be a CATPart)
Dim myDoc As Document
Set myDoc = CATIA.ActiveDocument

 'create an integer parameter
Dim thickness As IntParam
Set thickness = myDoc.Part.Parameters.CreateInteger ("Material Thickness", 2.0)

'create a real number parameter
Dim revision As RealParam
Set revision = myDoc.Part.Parameters.CreateReal("Revision", 2.5)

'create a string number parameter
Dim material As StringParam
Set material = myDoc.Part.Parameters.CreateString("Material", 2.5)


End Sub

For more, check out Scripting4v5.com.

6 comments:

  1. This comment has been removed by the author.

    ReplyDelete
  2. PPC Expert For Tech Support | inbound calls for tech support, pop up calls for tech support Call at: +91 981-142-0083 ppc management experts ppc call provide by osiel web
    PPC Promotion and marketing is very important to get the business for professional company especially for Tech Support & web design company.
    Google Adwords For Tech Support
    PPC Expert For Tech Support
    Inbound Technical Support call | Call at: +91 981-142-0083 | inbound calls for tech support tech support inbound calls A great online marketing company for tech support inbound calls, Inbound Technical Support call by osiel web

    ReplyDelete
  3. Nice Blog! Thanks for the useful info. I've come across a CAD customization expert online. CADVision is a solution provider by designing software products for engineers to efficiently resolve engineering challenges. Check it out.

    ReplyDelete
  4. thanks to sharing tutorials about catia maccro it is very helpful keep it up.

    ReplyDelete

I'd love to hear from you!