--- title: "Canceling a Workitem in a Workflow" slug: "canceling-a-workitem-in-a-workflow" updated: 2024-02-27T04:39:00Z published: 2024-02-27T04:39:00Z canonical: "help.pillir.io/canceling-a-workitem-in-a-workflow" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.pillir.io/llms.txt > Use this file to discover all available pages before exploring further. # Canceling a Workitem in a Workflow Q: My business usecase is a workflow app where employees fill out timesheets and submit them for approval. One of the requirement for the app is that when an employee starts filling out a new timesheet but decides to cancel it, the created workitem must be removed from the workflow. How do I design for this functionality? A: To cancel a workitem that is opened by mistake or to remove an unfinished workitem from the workflow, you need to link the action to a BOS. Within the BOS, add the '**Archive**' block, which effectively cancels or removes the created workitem. NoteThe following steps explain only the '**Cancel/Remove** **Workitem**' functionality. The other parts of the Timesheet app are not covered. **Steps:** To cancel a work item, follow these steps: 1. Add a '**CancelTimesheet**' **BOS** to the Timesheet page.![1-CancelBOS](https://cdn.document360.io/718af901-247b-46be-8ace-83da21839237/Images/Documentation/1-CancelBOS.png) 2. Within the BOS, incorporate an onCloud component. 1. In the Input Variables section, select the '**id**' variable from the Workitem Variables dropdown list. 2. Drag and drop the '**Archive**' block from the workflow component. 3. Assign the '**id**' variable to the **WorkflowId** field.![2-id](https://cdn.document360.io/718af901-247b-46be-8ace-83da21839237/Images/Documentation/2-id.png) 3. On the Timesheet page, configure the '**Cance**l' button interactions as follows: **onClick - Navigate to - CancelTimesheet**.![3-interactions](https://cdn.document360.io/718af901-247b-46be-8ace-83da21839237/Images/Documentation/3-interactions.png) By implementing these steps, the opened work item will be effectively canceled.