- This topic has 3 replies, 2 voices, and was last updated 7 years, 5 months ago by .
Viewing 4 posts - 1 through 4 (of 4 total)
Viewing 4 posts - 1 through 4 (of 4 total)
- You must be logged in to reply to this topic.
Home › Forums › eaDocX queries › Conditional formatting of 1-to-many relationships
Home › Forums › eaDocX queries › Conditional formatting of 1-to-many relationships
I’ve just realized that the conditional formatting applies to the whole cell of a table. This means it doesn’t do what you want when the cell contains the many-end of a 1-to-many relationship.
By way of an example I have a verification cross reference matrix which contains one requirement per row. Each requirement has one or more verification activities (VAs). Each VA has a type of Analysis, Test, Inspection. As this is all going into a table I wanted to abbreviate these to A,T,I using conditional formatting. So, without conditional formatting I might get a row like this
[table]
[tr]
[td][/td]
[td]V1[/td]
[td]Test[/td]
[/tr]
[tr]
[td]R1[/td]
[td]V2[/td]
[td]Analysis[/td]
[/tr]
[tr]
[td][/td]
[td]V3[/td]
[td]Inspection[/td]
[/tr]
[/table]
with conditional formatting I was hoping to see (ignore wider spacing, I don’t know why that is happening)
[table]
[tr]
[td][/td]
[td]V1[/td]
[td]T[/td]
[/tr]
[tr]
[td]R1[/td]
[td]V2[/td]
[td]A[/td]
[/tr]
[tr]
[td][/td]
[td]V3[/td]
[td]I[/td]
[/tr]
[/table]
but I just get
[table]
[tr]
[td][/td]
[td]V1[/td]
[td][/td]
[/tr]
[tr]
[td]R1[/td]
[td]V2[/td]
[td]T[/td]
[/tr]
[tr]
[td][/td]
[td]V3[/td]
[td][/td]
[/tr]
[/table]
because the conditional formatting checks for Test first (using “contains”) and so replaces the whole cell with T.
Is it possible to implement what I want, i.e. the conditional formatting applies to each entry in a cell rather than the whole cell?
Thanks, Mark
eaDocX treats the cell contents as a simple string, for the purposes of Conditional Formatting. How you have managed to make it the ‘many-end of a 1-to-many relationship’ is beyond me.
It shouldn’t be beyond you because that is what eaDocX does. When creating an element report you can “Add attribute of related element …”. That can find more than one “related element” – the dialog clearly expects it as, under “2 – Specify what to print”, it says “Then for each element found, print:”.
It looks like there are two capabilities in condition formatting: i) colouring the cell and; ii) text replacement.
It’s clear that i) has to be applied to the whole cell. What I’m after is for ii) to be modified to apply to each attribute or tv that gets placed as a comma-separated value in the cell, i.e. replace it before it gets written to the cell. I think that is more like the expected behaviour for ii).
Download eaTeamWorks today for several free for life features, plus no obligation, 30-day trials of all the products: eaDocX, ea Revision Manager, eaSheets, Model Expert and PortfolioManager. Discover for yourself why we sell the world’s best-selling Enterprise Architect extension.
Download