1) I would assume that you already have the template open or know how to open it from the server for type "Task" in project "SharePoint.Samples" (follow instruction on top to open the template)
2) We would add a drop-down with options and make this field mandatory
3) Switch to tab "Fields" and click "Add"
4) We are naming the new Field as "Solution Type" in tab "Field Definition" enter the detail as highlighted in the image below (Name : Solution Type | Type : String | RefName : SharePoint.Samples.Task.SolutionType | Reportable : dimension )
5) How do we make it a drop-down? Now change the tab to "Rules"
6) Click on "Add" and new window "Select a rule type" will popup
7) Select "ALLOWEDVALUES" which should be the first in list and click "OK"
8) In window "ALLOWEDVALUES" click on "Add"
9) In window "List Item Edit" add the value "Web Part" in "List Item" on click "OK"
10) Repeat two step above to add the following values "Page Layout", "Master Page", "Content Type", "Custom Lists"
11) When you have added all the value in window "ALLOWEDVALUES" click "OK"
12) Click "OK" in window "Field Definition"
13) Now we need to add this field to the form (UI) so that people can start using it
14) Switch to the tab "Layout" and locate "Group - Classification" underneath this right click on "Column" and click on "New Control"
15) Now edit the properties of control form the properties pane on right side of window
16) Change the property for "FieldName" and select "SharePoint.Samples.Task.Solution.Type" from the drop down (this it the custom field which we just created)
17) Change the property "Label" to "Solution Type"
18) Leave all other property values to default for this control
19) Now we have to make this value as Required (Mandatory) while new Task is created
20) Switch to tab "Workflow"
21) Right click on "Transition" (first blue box) and click on "Open Details"
22) In window "Workflow Transition" switch to tab "Fields" and click on "Add"
23) In window "Field Reference" select value for "RefName:"
24) Select "SharePoint.Samples.Task.SolutionType" from drop down and click "OK"
25) In window "Field Reference" switch to tab "Rules" and click on "Add"
26) In window "Select a rule type" select "REQUIRED" and click on "OK"
27) In window "REQUIRED" click on "OK"
28) In window "Field Reference" press "OK"
29) In window "Workflow Transition" click on "OK"
30)Now save the changes to template by "Ctrl+S"
31) After saving the changes refresh the project from Team Explorer, wait for some time after refresh and try to refresh couple of times and have some wait time between the refresh.
32) Open "Team Explorer" > Right click on the Project "SharePoint.Samples" > "Refresh"
33) To verify the changes now you should create a new task
34) Open "Team Explorer" > Expand the project "SharePoint.Samples" > Right click "Work Items" > "Add Work Item" > "Task"
35) Once the new task form is open, you should see your changes as per the image below, the filed is highlighted in yellow which denotes that this is required in order to create a new task
We are done!!
But what if we want to do this for all existing projects? Simple, we do export and import.
1) From VS Menu click "Team" > "Process Editor" > "Work Item Types" > "Export WIT"
2) Enter your server details and press "Connect"
3) You will now see all the projects in TFS, Select the Project and then expand it to select the work item type you want to export "Task" for this post and click "OK"
4) You will see the "Save As" window, browse to the location where you want to save, name the file and click "Save"
5) If you get popup window "Global List" asking "Would you like to include the Global List Definition?" click on "NO"
6) From VS Menu click "Team" > "Process Editor" > "Work Item Types" > "Import WIT"
7) In window "Import Work Item Type Definition"
8) Click on "Browse..." and locate the file which you saved earlier during "Export WIT"
9) Select the project to which you want to apply this template "CustomerService"
10) Click on "OK"
Its done, now to verify do as we did couple of time before, refresh the project "CustomerService" and then create the new task. You should see your changes applied.
for more information please read the given link read...
I am running this Blog to help other guys, who are looking some bits and pieces in terms of MS technology....
Thursday, December 22, 2011
How to enable or make editable Delete textbox in task with TFS 2008. How to Customize TFS 2008 work area?
Customizing the Work Item Tracking (WIT) Template
Changing work item templates, when new to team foundation server seems quite daunting - the first things I needed to learn about changing the work item templates were the witimport and witexport commands - these allow the import and export of XML definitions for work items on an existing project via the command line and editing the xml by hand was fiddly to say the least.
As said earlier TFS Power Tools makes this very simple by visually representing the XML for editing. The layout presented for editing the template look like a form layout which is quiet easy to work with.
Recently I had to modify the default Work Item templates for type Task to include a new custom field and also we needed to make the Task Start Date and Task Finish Date to be editable. The fields are editable in Database but are locked only in the UI. So we only have to make changes in the UI.
The reason these filed are read only is to prevent users modifying the dates. Often the tasks are loaded/imported from a MS Project Plan (.mpp) which has the Start Date and Finish Date along with dependencies and milestones. The effect of changing the date might change dates for other dependent task(s). MS Project can handle this, but when the date is modified in TFS Work Item and its synchronized with MS Project Plan the MPP is screw-up as this will not change the dependent tasks.
Now lets get the real action started, first I will show you how to make the Task Start Date and Task Finish date editable.
1. Making Task Start Date and Task Finish Date to be editable
1) Open Visual Studio (if not already open)
2) Open Team Explorer Window (Ctrl+\, Ctrl+M) (if not already open)
3) From VS Menu click "Tools" > "Process Editor" > "Work Item Types" > "Open WIT from Server" (Caution: You will be modifying this directly on the TFS Server so try to do it on Test Server rather than a production server)
4) Enter your server details and press "Connect"
5) You will now see all the projects in TFS, Select the Project and then expand it to select the work item type you want to edit Task for this post and click "OK"
6) You will see the screen similar to the one below, this is where you will be modifying the template. There are three tabs: Fields, Layout and Workflow. Fields Tab handles everything about the data/entity, Layout handles the rendering and view, Workflow defines how the data is transformed. You can also view the XML by clicking on View XML
7) As discussed earlier the fields Task Start Date and Task Finish Date are read-only in UI we will go to the Layout tab in order to make them editable.
8) Click tab "Layout"
9) Scroll down to locate "Control - Start Dat&e:", which is under "TabPage - Details" > "Group" > "Column" > "Group - Schedule"
10) Now in the properties for the control on right side of window select the property "ReadOnly" change the value to "False"
11) Repeat the step above to change property "ReadOnly" to "False" for "Control - &Finish Date:"
12) Now we need to change the type of control so that it will be rendered with standard date time control which we can use to select the date
13) On the properties pane of "Control - Start Dat&e:" select the property "Type" and change value from "FieldControl" to "DateTimeControl"
14) Repeat the step above to change the property "Type" for "Control - &Finish Date:" to "DateTimeControl"
15) Save the changes Ctrl+S or File > "Save__Task.wit"
16) After saving the changes refresh the project from Team Explorer, wait for some time after refresh and try to refresh couple of times and have some wait time between the refresh.
17) Open "Team Explorer" > Right click on the Project "SharePoint.Samples" > "Refresh"
18) To verify the changes now you should create a new task
19) Open "Team Explorer" > Expand the project "SharePoint.Samples" > Right click "Work Items" > "Add Work Item" > "Task"
20) Once the new task form is open, switch to "Details" tab and you should see your changes as per the image below
For More information please read SharemyPoint
Changing work item templates, when new to team foundation server seems quite daunting - the first things I needed to learn about changing the work item templates were the witimport and witexport commands - these allow the import and export of XML definitions for work items on an existing project via the command line and editing the xml by hand was fiddly to say the least.
As said earlier TFS Power Tools makes this very simple by visually representing the XML for editing. The layout presented for editing the template look like a form layout which is quiet easy to work with.
Recently I had to modify the default Work Item templates for type Task to include a new custom field and also we needed to make the Task Start Date and Task Finish Date to be editable. The fields are editable in Database but are locked only in the UI. So we only have to make changes in the UI.
The reason these filed are read only is to prevent users modifying the dates. Often the tasks are loaded/imported from a MS Project Plan (.mpp) which has the Start Date and Finish Date along with dependencies and milestones. The effect of changing the date might change dates for other dependent task(s). MS Project can handle this, but when the date is modified in TFS Work Item and its synchronized with MS Project Plan the MPP is screw-up as this will not change the dependent tasks.
Now lets get the real action started, first I will show you how to make the Task Start Date and Task Finish date editable.
1. Making Task Start Date and Task Finish Date to be editable
1) Open Visual Studio (if not already open)
2) Open Team Explorer Window (Ctrl+\, Ctrl+M) (if not already open)
3) From VS Menu click "Tools" > "Process Editor" > "Work Item Types" > "Open WIT from Server" (Caution: You will be modifying this directly on the TFS Server so try to do it on Test Server rather than a production server)
4) Enter your server details and press "Connect"
5) You will now see all the projects in TFS, Select the Project and then expand it to select the work item type you want to edit Task for this post and click "OK"
6) You will see the screen similar to the one below, this is where you will be modifying the template. There are three tabs: Fields, Layout and Workflow. Fields Tab handles everything about the data/entity, Layout handles the rendering and view, Workflow defines how the data is transformed. You can also view the XML by clicking on View XML
7) As discussed earlier the fields Task Start Date and Task Finish Date are read-only in UI we will go to the Layout tab in order to make them editable.
8) Click tab "Layout"
9) Scroll down to locate "Control - Start Dat&e:", which is under "TabPage - Details" > "Group" > "Column" > "Group - Schedule"
10) Now in the properties for the control on right side of window select the property "ReadOnly" change the value to "False"
11) Repeat the step above to change property "ReadOnly" to "False" for "Control - &Finish Date:"
12) Now we need to change the type of control so that it will be rendered with standard date time control which we can use to select the date
13) On the properties pane of "Control - Start Dat&e:" select the property "Type" and change value from "FieldControl" to "DateTimeControl"
14) Repeat the step above to change the property "Type" for "Control - &Finish Date:" to "DateTimeControl"
15) Save the changes Ctrl+S or File > "Save
16) After saving the changes refresh the project from Team Explorer, wait for some time after refresh and try to refresh couple of times and have some wait time between the refresh.
17) Open "Team Explorer" > Right click on the Project "SharePoint.Samples" > "Refresh"
18) To verify the changes now you should create a new task
19) Open "Team Explorer" > Expand the project "SharePoint.Samples" > Right click "Work Items" > "Add Work Item" > "Task"
20) Once the new task form is open, switch to "Details" tab and you should see your changes as per the image below
For More information please read SharemyPoint
Subscribe to:
Posts (Atom)
Split the String values with a special character in MS Flow to convert this into Array
Many times we have a requirement to prepare the Mailing address for some of the documents, suppose there are Address Line1, Address Line2, ...
-
Use the following line of code to Reopen the closed task in CRM 2011 // Re-open the Task to update it SetStateRequest ssr = new SetStat...
-
Use the following line of code to create complete workflow activity with two output parameters. 1) Open Visual Studio 2010 ID. 2) Open ...
-
Sometimes you experienced when you have subgrid in your CRM Form, but when you click the ‘expand’ button to expand the view then it will re...