×
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

VBA to Inactivate View from current sheet

VBA to Inactivate View from current sheet

VBA to Inactivate View from current sheet

(OP)
Hi,

I'm trying to inactivate view since I have previously activate it for modification purpose. Unfortunatly, I did'nt find any opposite method of Drawingview.activate. Does any one know a way to do this in VBA.

Thanks

RE: VBA to Inactivate View from current sheet

(OP)
Hi Ferdo,

I want to close my drawing without any active view. Activate a sheet does not desactivate view.

Regards

RE: VBA to Inactivate View from current sheet

Interesting, for me it does...

CODE --> CATScript

Language="VBSCRIPT"
Sub CATMain()

CATIA.StartCommand "Fit All In"

Dim drawingDocument1 As Document
Set drawingDocument1 = CATIA.ActiveDocument
Dim selection1 As Selection
Set selection1 = drawingDocument1.Selection
selection1.Search "Name=Sheet*,all"

CATIA.StartCommand "Activate Sheet"
selection1.Clear

CATIA.StartCommand "Save"

End Sub 

Regards
Fernando

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

RE: VBA to Inactivate View from current sheet

(OP)
Hi Ferdo,

Your right, if I make search to select all Sheet, it works find. I don't understand why ?

Thanks for your support

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