Author Topic: Updating title blocks  (Read 1153 times)

0 Members and 1 Guest are viewing this topic.

Totores

  • Newbie
  • *
  • Posts: 7
Updating title blocks
« on: June 29, 2023, 06:24:28 PM »
Good morning,
need help, I have created a drawing template and my custom title block, I have duplicated the tabs so that I now have 3 of the same drawing.
Is it possible to fill the title block on the front page and have the fields in the other 2 tab pages update?

P.S. my organization IT will not allow macros to run.

Thanks

wapperdude

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4838
  • Ideas Visio-lized into solutions
Re: Updating title blocks
« Reply #1 on: June 29, 2023, 08:20:04 PM »
Yes you can do this within the shapesheet without macros.

Here is the general description about building cell references:  https://learn.microsoft.com/en-us/office/client-developer/visio/about-cell-references.

What you're after is the Page/Shape/Cell construction.  The necessary syntax is provided.

See the attached file.  The shape on page2 references the User Section, with a named row, on Page1.  Both shapes use  field insert to display the entry in the shape1.  All done within shapesheet.
« Last Edit: June 29, 2023, 08:37:51 PM by wapperdude »
Visio 2019 Pro

Totores

  • Newbie
  • *
  • Posts: 7
Re: Updating title blocks
« Reply #2 on: June 29, 2023, 09:43:49 PM »
Thanks, I will need to work through it.
All I need is to enter the project number in the cell on the front page title block and the same project number will appear on the same cell in the following pages/tabs

wapperdude

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4838
  • Ideas Visio-lized into solutions
Re: Updating title blocks
« Reply #3 on: June 29, 2023, 09:50:38 PM »
Yep.  That is what the attached file demonstrates.  Not knowing your actual implementation, the file uses a row in the User Section of each shape on each page.  The 2nd page shape has a formula that fetches the entry from the 1st page shape.  The syntax is there.  You need to modify formula for your specific case.

The reference link has a table for various possible cases.  It can be of use for future scenarios.
Visio 2019 Pro

Yacine

  • Hero Member
  • *****
  • Posts: 3208
Re: Updating title blocks
« Reply #4 on: June 30, 2023, 01:25:54 AM »
Yes, it is feasible as Wapperdude showed, but think also about using a background page, which would be Visio's standard approach.
Yacine

Totores

  • Newbie
  • *
  • Posts: 7
Re: Updating title blocks
« Reply #5 on: July 10, 2023, 07:29:21 PM »
Thanks all for your comments, I did find a tutorial that covers exactly what I was trying to achieve (https://www.youtube.com/watch?v=toweOQWHSCI)
I have managed to duplicate this on a simple blank 3 pages blank project, however, when I apply this to a project created by someone else containing 6 pages when I enter this formula

=SHAPETEXT(Pages[Plan1]!Sheet.1235!TheText)

I get "error in formula" error and I can't figure out what's the error is.

The project is a drawing not a template
Not sure if the pages where originally duplicated or inserted
The example above is from a box created in an "inserted page" linking it to a box in the front page
The front page is called Plan1
The reference box is Sheet.1235
 

wapperdude

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4838
  • Ideas Visio-lized into solutions
Re: Updating title blocks
« Reply #6 on: July 10, 2023, 10:04:30 PM »
The most likely culprit is the page name.  Visio has both a local and universal name for pages.  If a page has been renamed more than once, these get out of sync.  See this link for simple code to relaunch the universal and local names.  It will go thru entire file and update the universal name to match the local name.  The local name is the one displayed on the page tabs.  After it runs, your formula should work as is.

http://visguy.com/vgforum/index.php?topic=9693.msg43645#msg43645.  Note, you can run the macro once and delete it.  As long as the page names are not altered, you will not need it.  Save the document. 

« Last Edit: July 10, 2023, 10:34:38 PM by wapperdude »
Visio 2019 Pro

Surrogate

  • Hero Member
  • *****
  • Posts: 1805
    • ShapeSheet™ Knowledge Base
Re: Updating title blocks
« Reply #7 on: July 10, 2023, 11:45:05 PM »
The most likely culprit is the page name.  Visio has both a local and universal name for pages.  If a page has been renamed more than once, these get out of sync.
Few years ago i created this solution.
Hope my Snippet for ShapeSheet can helps you
Please try this way…
P.S. my organization IT will not allow macros to run.
Ooops…
« Last Edit: July 11, 2023, 12:45:29 AM by Surrogate »

wapperdude

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4838
  • Ideas Visio-lized into solutions
Re: Updating title blocks
« Reply #8 on: July 11, 2023, 10:15:29 AM »
@Surrogate:  the macro restriction is a valid point, but it was NOT an oversight.   AFAIK, there is no other mechanism within Visio to re-sync the page names.
1) The code is simple enough, that it could easily be written manually.  Thus, there is no imported macro ban violation.
2) Presumably, the macro ban doesn't apply to in-house automation.
3) Once run, the code can be removed/deleted.  It would not remain a residual part of the file.

There are two alternatives:
1) manuall change each and every page, any and every time a change is made to the source page
2) per Yacine's suggestion, put the title block on a background page, and then edit each page's properties to include the background page.  Thus, only the BkGnd page needs editing.

Not aware of any other alternatives.
« Last Edit: July 11, 2023, 08:04:34 PM by wapperdude »
Visio 2019 Pro

Totores

  • Newbie
  • *
  • Posts: 7
Re: Updating title blocks
« Reply #9 on: August 02, 2023, 07:17:13 PM »
My apologies for not getting back to you guys been really busy recently :(, first of all I would like to thank everyone for their comment. I did find a solution.

As my design is very simple, I:
- Create a new document
- Create new tabs for my need in the new document
- Copied all the elements from the old document tab 1 to the new document tab 1
- Copied all the elements from the old document tab 2 to the new document tab 2

Closed the old document and then followed the instruction from (https://www.youtube.com/watch?v=toweOQWHSCI) in the new document. It all worked as I wonted it to.

Thanks again to everyone.