LarryO Posted March 7, 2015 Share Posted March 7, 2015 Anyone know why Layer() doesn't completely switch to the active layer when in the user is in Viewport Annotation mode? Or is there another function I'm not aware of in lieu of PickObject that accepts coordinates and a layer handle? I use: VSave('TempView'); GetPt(SelectPtX,SelectPtY); ObjPtX:=SelectPtX-(VPOriginX*VPScale); ObjPtY:=SelectPtY-(VPOriginY*VPScale); Layer(Lname); PIOObjh:=PickObject(ObjPtX,ObjPtY); VRestore('TempView'); VDelete('TempView'); in that order but PickObject() doesn't detect the object at the specified location. If I don't restore the saved view I am left seeing the specified layer on screen but only the now invisible objects that were in the annotation area of the viewport remain selectable. The exit viewport annotation button also is active in the top right corner. So vectorworks still thinks I am editing annotation but now shows the specified active layer objects which do not appear to be selectable. As per my previous message I am attempting to get a handle to an object that I see while in viewport annotation mode in order to extract data from said object. I will capture the visible layers of the viewport and I attempt to use the calculated point with PickObject() to get the object's handle before returning the user to viewport annotation mode. Thanks Quote Link to comment
LarryO Posted March 9, 2015 Author Share Posted March 9, 2015 Resolved I needed to exit viewport annotation mode before attempting to change layers. DoMenuTextByName('Group Navigation Chunk',2); Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.