Jump to content
Developer Wiki and Function Reference Links ×

How to hide a worksheet?


G Kinney

Recommended Posts

Help please. Im Using VectorScript for VW10. MAC.

Basicly I want to do the oppositte of CreateWSImage. I want to rename an exisitng worksheet that is displayed on the sheet to another name, so as to keep a record of the old data. Then hide that worksheet, as its outdated data. Then recreate a new worksheet using the original name with entirely updated data, and display that worksheet in its place. Everything I script won't hide the original sheet (renamed 'sheet.old'), and won't display the new sheet (of the Original name). In the resource pallet the 'Sheet.old' worksheet is listed as "ShowOnDrawing" and the new one is not? Is there a method to Hide a worksheet?

Link to comment

I was able to solve the issue by using named objects for my Worksheets instead of the actual resourse name of the worksheets. Thanks to Fuge on a different worksheet post.

A note though... I dont like having to use named objects inside scripts. As projects grow and further tools are adopted, makes more to keep track of. This should be fixed by VW. [smile]

Link to comment

If you have a handle to the worksheet, you can pass it to GetWSImage to get the image node and then delete the image node. This will change the "on drawing" state.

theImage := GetWSImage(theWorksheet);

SetSelect(theImage);

DeleteObjs;

Jeff

Link to comment

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...