Close applications activity is giving me an exception


The following Exception is throwing while closing a notepad application opened by a sequence.

How can i fix this…




Could you please share with us the arguments that is passed on Close Application activity?



Hello Lucas,

Nothing i am passing… i am a beginner. can you brief me how can i handle it. attached is the screen of properties of close applications activity.



please can you expand the ‘target’ field in the above screenshot and take a screenshot of the full selector, and also one of the notepad window you are trying to close?


Hello Djh,

here is the screen shot… my doubt here is, drag and drop close applications activity is enough to close the opened notepad, or else do we need to configure anything to do so…




You must have to indicate the application that you want to close.

On the close application activity, click on “Indicate on screen” then select the opened Notepad.

Hope It Helps!




Thank you for your suggestion. i am opening the application using open application activity, since it is opening in middle of execution and writing some text into it, how can i go with indicate on screen option here…


Close application activity: Indicate on screen and specify the application.



To your better understanding follow below a example:

OpenCloseNotepad_Example.xaml (9.1 KB)

Hope It Helps :smiley:


when you place the close application activity, it will look like the below. click on ‘indicate on screen’ and then click the notepad window, which should go blue. This will set the close application activity to the notepad application


You ll need to place close activity in attach windiw. Also add the selector in the attach window activity.


Hi Avnesh,

  1. Add activity of a close application
  2. Click on “Indicate on screen”
  3. point the cursor on close symbol/picture and drag on it.
  4. Selector path will be captured.
  5. Add regular expression to make it dynamic.

Hope this will help else let me know further.


Hi Friends,

I am new to UiPath. When I am trying to close application even I am getting the same error message.
My close application activity is looking like this:
And my Activity Panel is like this when I am trying to select close application activity:
Can someone suggest what to do?


Are selecting the opened application? Since you select it, the selector property will fill with the application information that need to be closed. Without this, Uipath cannot know which application needs to be closed :open_mouth:

Hope it Helps :wink: