Visio Guy

Visio Discussions => ShapeSheet & Smart Shapes => Topic started by: shinji7800 on February 24, 2021, 12:27:37 PM

Title: shapedata and conditional label
Post by: shinji7800 on February 24, 2021, 12:27:37 PM
Hi everyone,

I am trying to set a simple formula for a conditional label for a shapedata.

=IF(STRSAME(sheet.65!Prop.DR, "NRS"), "Interface Fa x/0/y : ", "interface Gi 1/x : ")

Label became dynamic,  but value (set by user) is not updated ... there is no dependencies and precedents so I have no clue what's going on.

please find here an exemple on video : https://youtu.be/wiYMynCw2u0 (https://youtu.be/wiYMynCw2u0)

if you prefer I can provide a google drive link

thanks

best regards
Title: Re: shapedata and conditional label
Post by: Surrogate on February 24, 2021, 01:18:10 PM
At my side it works ! But when i use used-defined data which stored in TheDoc, sometimes i have problems with update text values...
(http://forumimage.ru/uploads/20140818/140835070128749569.gif)
Title: Re: shapedata and conditional label
Post by: shinji7800 on February 24, 2021, 01:43:57 PM
Hi Surrogate !

thanks for your time !

but I not sure if I explain well my issue ...

I use shapesheet with formula (IF statement) for conditional lable in shapedata.


your gif example seems to me, a "simple" field

am I wrong ?
Title: Re: shapedata and conditional label
Post by: Surrogate on February 24, 2021, 03:42:59 PM
Quote from: shinji7800 on February 24, 2021, 01:43:57 PM
your gif example seems to me, a "simple" field
no, that shape contain 2 fields. In this gif you can see how changed only one of them.
Also i can changed "second field", which contain date. It is conditional !
My solution enought complex, it is reason why sometimes not all fields are updated...
Title: Re: shapedata and conditional label
Post by: Surrogate on February 24, 2021, 04:05:32 PM
Quote from: shinji7800 on February 24, 2021, 12:27:37 PMif you prefer I can provide a google drive link
IMHO it is best way, for investigation...
Title: Re: shapedata and conditional label
Post by: shinji7800 on February 24, 2021, 05:29:06 PM
For sharing .vss files ?
Title: Re: shapedata and conditional label
Post by: Surrogate on February 24, 2021, 05:36:46 PM
Any kind of files...
Title: Re: shapedata and conditional label
Post by: shinji7800 on February 26, 2021, 02:24:27 PM
hi all ,

it seems that label and value cells don't like when there is calculation.

so I double rows and hide one of them conditionally. result is the same for user :)


I will post a video for additional exemple maybe it helps :)


best regards

 
Title: Re: shapedata and conditional label
Post by: wapperdude on February 27, 2021, 05:58:21 AM
Uploading the file would be helpful.

How are you transferring the information to the shape for display?  Are you using Insert>Field?
Title: Re: shapedata and conditional label
Post by: shinji7800 on February 27, 2021, 06:51:43 AM
Hi

Yes I use  insert > field (ctrl + F9) > custom formula

For exemple on my initial non working test

Let shape A with props,

on shape B ctrl+F9 > custom formula

=shapeA!Props.row1.value


The alternative I find (even I will prefer the non working :D)

Is on shape A create an another props :

- let row1 for a specific case (imagine for daytime)
- let row2 for an another specific case (imagine for night time)

For the Each rows add if statement in "invisible" cell
- row1.invisible = IF(daytime, FALSE, RIGHT)
- row2.invisible = IF(daytime, RIGHT,FALSE)

on shape B ctrl+F9 > custom formula

=IF(daytime, shapeA!Props.row1.value,shapeA!Props.row2.value)


I will post files as soon I can :)

Hope it helps

Regards

Title: Re: shapedata and conditional label
Post by: Machine on May 27, 2021, 04:51:13 PM
I'm pretty much sure I had similar situation long time ago.
Because of some reasons If-statement behaves like a Guard if shapes are grouped together.

What you could do, is to change Label via SETF/GetRef.
Basically force the Label change from the shape where you got your List (NRS;DRP).