Data Graphic Text Position

Started by Blake Dot C, September 01, 2016, 08:04:18 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Blake Dot C

Hi All,

I've been troubleshooting this for days and I'm reluctant to say that there simply isn't a solution for such.  I've found other instances of this problem here and elsewhere with no answers ever given.  HELP!!??

I am working with Visio 2010 Professional and I am linking spreadsheet data to already created shapes using Data Graphics.  These shapes are fairly small rectangles with 3 lines of text.  I have imported the data, and created data shapes for the rectangles; however, the default data (text) positions are useless.  They position the data well outside of the defined area I would like them in, and no amount of finagling the "up, down, mid" or  callout widths puts them in the correct positions.  I can manually drag the text to where I want, but that only changes a single rectangle, and does not define the position of each subsequent data graphics.  Manual positioning is also reset once the data is refreshed or updated.  I have tried to change the text positioning in the master shape for the data graphic by dragging the text around and messing with the code, but but that has no affect.    I also just tried opening the master to the "Heading 2" (which is the data graphic field template I'm using).  I had a slight success there by modifying the Shape Transform parameters, but as soon as I refreshed the data, all went back to the default format. Is there a way I can set a default custom position for the data graphic that will apply to each shape and position the text at a certain position?  I am guessing there is some language in the Master Shapesheet to modify these parameters, but I keep coming to a dead end regardless of what I try.

Thanks!!

Yacine

Trying to understand your question, I set up a shape with some custom props, linked it to a row of a linked excel file, applied a data graphic and moved it to the doc stencil.
All the rows dragged from the doc stencil had the same adjusted properties.
Could you upload an example so we could understand better your intention?
Yacine

Blake Dot C

Quote from: Yacine on September 02, 2016, 07:08:04 AM
Trying to understand your question, I set up a shape with some custom props, linked it to a row of a linked excel file, applied a data graphic and moved it to the doc stencil.
All the rows dragged from the doc stencil had the same adjusted properties.
Could you upload an example so we could understand better your intention?

Ok so hopefully I am missing something considering I don't exactly understand a couple of your points.  What do you mean by "set up a shape with custom props"?  And "moved it to the doc stencil"?  What did you drag from the doc stencil?

My intention is to arrange the text displayed by a data graphic in a manner not allowed (or different) from the preset data graphic options (horizontal: left, left edge, right, etc and vertical:  mid, bottom, bottom edge, etc).  None of these preset formats actually work for my shape, which is a simple small rectangle.

The first picture is of the default (center, middle) setting.
The second picture is of the 2nd row of text set to (center, bottom).
Regardless of the configurations I've tried, I cannot get the text to actually sit inside the box.  Hopefully this clarifies my issue, please advice if you can and thanks a ton!

Blake Dot C

I GOT IT I GOT IT!!!  Thank you so much for the little insight!!!!  ;D ;D

So what I had to do was as follows.  Link the data to a blank rectangle and create a custom data graphic.  Drag the linked rectangle into the document stencil, edit the master shape, and arrange the text how I wanted.  Exit the master shape editor and save.  Once I did this, I found that the original link became unlinked (IDK WHY?)  Once I relinked the shape to the correct data, all text stays how I want, and the data updates on the refresh...GREAT!!!

Now I just have to replace every existing rectangle with the master shape I created so that the text will layout correctly...tedious but worth it.

THANKS!!!

Yacine

I hope V2010 has it already, in V2013 you got a possibility to replace a shape in the drawing by another in a stencil.
This may help you.
Yacine

Yacine

By the way, you wouldn't have needed datagraphics at all.
Just edit the text by pressing F2, then insert field, goto the shape data section, chose the right field and insert. hit enter to insert a line break, then go to insert field again, etc.
Yacine

Blake Dot C

Ok...so I'm back to having trouble with this stupid feature.  I don't know how you got the box to display that allows the existing shape to be replaced with one in the stencil.  Can you explain?

Also, you are correct in the fact that I do not actually need the datagraphic feature...I definitely did not realize this.  It's weird though because it does not show a "link" icon in the external data tab when a field is inserted, but it does update when the data is changed.

My problem now is I've changed utilities, (think water, steam, ect)..and my source excel is formatted slightly different.  Thus my stencil I created originally will not work, awkwardly.  For example, I put my previously created stencil (the rectangle with 3 fields) into my new sheet.  I import my data source.  I drag my data source into the rectangle.  My source columns are slightly different, say F2 is name instead of F3.  When I go to edit the data graphic, F2 is not available.

So...I've gone to making a new stencil for this utility.  BUT...when I do the exact same thing that worked the first time....it will not work.  I drag my data into a BLANK rectangle, one that has no data graphic or text.  I set a NEW data graphic which sources the data correctly, and my text is again awkwardly placed (same problem as original).  I drag the rectangle into the document stencil to change the text position, click edit master, and nothing....all I see is a blank rectangle.  No text to arrange.  I've tried the same thing using your suggestion, no datagraphic but just inserted field.  That works, but I still need to position the text correctly.  When I drag the rectangle into the document stencil, there is no text, even though text is clearly displayed on both instances (both using the datagraphic and using the field insert options).  UGHH...Visio is the worst.

Blake Dot C

Sorry for blabbering...once again I've figured it out.  Starting from scratch and editing the Master Stencil I was able to find the hidden text by zooming out to 5%.  For some reason it was about 6 miles from the original shape.  Hopefully crisis avoided.

kriskizlyk

Yes, this worked for me in Visio 2016.  I needed a different Style/Heading for a Data Graphic for a Electrical Panel Layout using Designators and IDs and such.  What my pickle trying to find or even create new styles.  Thankfully with your hints, they are located in the Drawing Explorer.  Here was my process, and in my case all I wanted to do was rotate the heading it 90'.

Sorry for the potato graphics.
1. In the Ribbon select Developer > Drawing Explorer
2. Under the Drawing Explorer Navigate to: Masters > The object to change, in my case it was the the Heading 2.
3. Right Click and Duplicate it and give it a name that you want, in my Case "DesignatorID"
4. Right Click your new item and then "Edit Master Shape"
5. Right click the object to show ShapeSheet.
6. Protection.LockRotate = 0
7. Change the objects rotation angle to 90'
8. Save and close the Master Shape.
9. In Ribbon select Data > Advanced Data Graphics > Edit Data Graphic
10. Edit item and change the style to the new "DesignatorID"