private void btnInstanceFree_Click(object sender, EventArgs e) { // Create a new Batch instance // Logs onto the CSM with "AdvancedDemo" application // and "FormId" station Batch b = new Batch("AdvancedDemo", "FormId"); // Gets the collection "00000001" ITisCollectionData collData = b.Get("00000001"); // Put the collection (writes it back) // to the CSM and keeps it in the same // queue b.Free(collData); MessageBox.Show("Collection: " + collData.Name + " is still in the same queue"); // Dispose the batch instance // and disconnect from the CSM b.Dispose(); }