×
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

Need help in searching and selection of part

Need help in searching and selection of part

Need help in searching and selection of part

(OP)

I have a hybrid shape "INtersect in a know geometric set. I would like to do the selection automatically which is in the Geometric set named " geometric_Set_Disassemble rather specifying the name of the intersect

Any suggestions. My actual code is given below

Dim hybridbody8
Set hybridbody8 = hybridBodies1.Item(" Geometric_Set_Disassemble")
Set hybridShapes1 = hybridbody8.HybridShapes
Set selection1 = partDocument1.Selection

Set Disassemble = hybridShapes1.Item("Intersect.2")
CATIA.ActiveDocument.Selection.Add (Disassemble)


Dim hybridbody9
Set hybridbody9 = hybridBodies1.Add()
hybridbody9.Name = " Disassembled_Lines"
'sets the newly created geometrical set as the in work object
Set hybridbody9 = hybridBodies1.Item(" Disassembled_Lines")

CATIA.StartCommand ("Disassemble")
' WshShell.AppActivate ("Disassemble")
'Call WshShell.SendKeys("%{TAB}", True)
CATIA.RefreshDisplay = True
SendKeys "{ENTER}", True

RE: Need help in searching and selection of part

I suppose is vba because in CATScript send keys is not working (as far as I know). Is working thru a vbs file (calling the vbs in CATScript).

By the way, when use send keys is good to set also a delay to let time command to be executed.

You can use also "user selection" to get the element you need and work with references.

If you want to use search function to select something I can recommend you this link to understand better how is working.

Regards
Fernando

https://picasaweb.google.com/102257836106335725208
https://picasaweb.google.com/103462806772634246699...

RE: Need help in searching and selection of part

(OP)
Hi ferdo

yea You are right. Send keys dont work in CATScript thats y opted VBA and as per suggestion added delay code bfore send key execution.

And thanks for that useful link, it was more than useful

Thanks and regards
Barath

RE: Need help in searching and selection of part

(OP)
Hi ferdo

I found the syntax for selecting the object named Intersect. but bfore that how do i select the geometric set. I need the intersect object only from the specified geometric set..

Any suggestion

Regards
barath

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