TFS WIT Field duplication
-
Friday, April 20, 2012 3:34 PM
Is it possible to create a second field on another tab that would be a read-only duplicate of another field?
In other words, can I create a field that is called 'Testing Done' on one page that would receive updates. Then, create a field called 'Testing Methods' on another page that would already have the information from 'Testing Done'?
All Replies
-
Monday, April 23, 2012 2:08 AMModerator
Hi BossHogg,
Thank you for your post.
what do you mean by "one page", "another page", can you show us some screen shot to explain them?
Best Regards,
Lily Wu [MSFT]
MSDN Community Support | Feedback to us
-
Monday, April 23, 2012 12:52 PM
Sorry for the vagueness...Let's say for the two fields below (Solution Implemented & Unit Testing Done) I create a similar box on the 'Testing' tab that I have for those on the 'Solution' tab. I want the information that gets entered on the 'Solution' tab to duplice over to the 'Testing' tab for those two boxes, but I am going to make those read-only fields.
Is that possible?
-
Tuesday, April 24, 2012 8:03 AMModerator
Hi BossHogg,
I think there are two points we need to accomplish to meet your needs.
1. Another two fields in Testing tab, and the value of them are copy from the two field in Solution tab. Here we call Solution Implemented and Unit Testing Done fields in Solution tab as Solution_fields, call the other fields in Testing tab as Testing_fields.
2. After copy the value from Solution_fields, Testing_fields should READONLY.But,
1. COPY and READONLY are field rules, not layout control attribute. Once you set the field rule, the rule will be applied when the field exists. So we cannot let field rule valid in one layout, but invalid in another layout. Field rule will be applied once been set.
2. If you need edit Solution_fields in future, but Testing_fields are READONLY, how let Solution_fields and Testing_fields keep same?I suggest you write a custom work item control, or submit a feedback to Visual Studio UserVoice site (http://visualstudio.uservoice.com/forums/121579-visual-studio). Microsoft engineers will evaluate them seriously.
Best regards,
Lily Wu [MSFT]
MSDN Community Support | Feedback to us
- Edited by Lily_WuMicrosoft Contingent Staff, Moderator Tuesday, April 24, 2012 8:04 AM
-
Tuesday, April 24, 2012 12:28 PM
So, you are saying, that in the meantime it is possible to copy the information over, but not make it read-only unless I do some custom programming?
How do I have it copy over for now?
-
Wednesday, April 25, 2012 1:43 AMModerator
Hi BossHogg,
If you do not want Testing_fields READONLY, you can set field rule to copy value from Solution_fields. Create another field in Testing tab, set copy rule for this testing field..
<FieldDefinition refname="my.testing" name="Testing_fields" type="HTML">
<COPY from="field" field="my.soution" />
</FieldDefinition>Best regards,
Lily Wu [MSFT]
MSDN Community Support | Feedback to us
- Marked As Answer by BossHogg20 Thursday, April 26, 2012 2:01 PM
-
Wednesday, April 25, 2012 1:55 PM
Thanks.
Before I make a suggestion to http://visualstudio.uservoice.com/forums/121579-visual-studio , do you know of a way to implement the 'WhenChanged' portion that allows you to switch the field to 'ReadOnly' after the copy?
-
Thursday, April 26, 2012 1:44 AMModerator
Hi BossHogg,
I'm afraid you need write a custom work item control yourself or submit a feedback to uservoice site.
Thanks,
Lily Wu [MSFT]
MSDN Community Support | Feedback to us

