×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

macro problems

macro problems

macro problems

(OP)
I can't seem to record macros using MSVBscript or CATscript. The packaged macros work fine, and it looks like I'm recording a macro, but when I go to run it or edit it there's nothing. Thanks in advance for any help.

RE: macro problems

Hi!
I believe the macro recorder will not work in every workbench. It also will not work in background view, I believe.
The documentation is not to good for beginners ( I am one ), I think, but you can learn a lot from looking at sample scripts on how to get to the objects you're after.

RE: macro problems

hi,

i made some vba macros that change some text in background view, it works.

Eric N.

catiav5@softhome.net

RE: macro problems

(OP)
Thanks for the help. It looks like a macro won't record in the Drafting Workbench. Does anyone know if this is a software default or if there's a patch for this problem?
THanks again.

Al

RE: macro problems

Hi Eric.N
Can you let me know the code for selecting the Text in Background view???
I was not able to get it......

One more Issue is, CATIA VB Editor works in my system some time and some time VB Editor is grayed out. i work with P4, 2GB Ram V5R8. I have tried to copy the CATSetting file when it was working and use the same when it is not working,but to no effect.
Any help on this regard is appreciated

Cheers
Ganesh.N

ganesh.n@engg.tjc.co.in

RE: macro problems

hi,

on order to get the text name "NameOfTheText" in background and set the value to "You got it !!":

set YourDrawing    as  DrawingDocument
set YourSheet      as  DrawingSheet
set BackgroundView as  DrawingView
set MessageText    as  DrawingText


YourDrawing = CATIA.ActiveDocument
YourSheet = YourDrawing.Sheets.ActiveSheet
BackgroundView = YourSheet.view.item(2)

MessageText = BackgroundView.Texts.GetItem("NameOfTheText")

MessageText.text = "You got it !!"


That should help you if you know a little bit of VBA with CATIA

Eric N.

catiav5@softhome.net

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources