By Wayne Brill
This zip contains a VS 2010 C# project. (Tested with Vault Pro 2013)
Download Changeordersample2013
When you run the program a form is displayed:
What this sample demonstrates is a way to do the following:
- Create a new Change Order
- Submit an activity for a Change Order
- Update a Change Order
When the form is started it instantiates a class named PSHelper. In the constructor for this class global variables for ItemService, ChangeOrderService and WebServiceManager are created. These objects are used in the functions that are called when you click one of the three buttons.
Use the top text box to input a value of a property of one of the Items in the Vault that you are connecting to. The second textbox is where you input the number of the Change Order. Keep in mind that once a change order is created you will need to change the number. Also once an Item is referenced to a Change Order using the item again will cause an error. (1612 “The item is being managed by another change order”). You may need to update Vault Explorer to see the effect. (I just hit F5)
Note: This example uses localhost as the server address and you may need to change it for your environment. You can see this in the PSHelper constructor.