# Not shutting down after error occured

**URL:** <https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892>\
**Category:** Asset Creation\
**Tags:** question, realityscan\
**Created:** [May 28, 2024, 11:55am UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892 "2024-05-28T11:55:57Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![KlartRu](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@KlartRu](https://forums.unrealengine.com/u/KlartRu)\
**Post date:** [May 28, 2024, 11:55am UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892/1 "2024-05-28T11:55:57Z")

</div>

I’m using circular markers to define my reconstruction region. Sometimes a marker is not found and I run into the following error:  
“Set Reconstruction Region on Control PointsSet Reconstruction Region  
Invalid or corrupted input data  
Point … not found. [err:5626]”

Now I have 2 questions:

1. I would like RC to quit on error, to proceed to the next job waiting in the script, but  
-set “appQuitOnError=True” ^ does not do the trick. RC is waiting until I click close. How can I fix this, and omit waiting the whole night on this error.

2. In my scenes different marker can be found and used as an alternative, when the standard ones are not found. Is there an elegant way to script the use of alternative markers when the first choice isn’t found?

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![OndrejTrhan](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ondrejtrhan/32/906565_2.png) [@OndrejTrhan](https://forums.unrealengine.com/u/OndrejTrhan)\
**Post date:** [May 28, 2024, 12:42pm UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892/2 "2024-05-28T12:42:54Z")

</div>

Hi Klart,  
I tested the first issue and for me it worked using these commands:

```auto
"C:\Program Files\Capturing Reality\RealityCapture\RealityCapture.exe" ^
-set "appQuitOnError=true" ^
-addFolder "C:\Documents\Benchmarks\folder" ^
-setReconstructionRegionOnCPs "1" "2" "3" "4" ^

```

The application quit for me.

For your second case you can use [Supress error messages](https://rchelp.capturingreality.com/en-US/tutorials/commandline_5.htm#:~:text=Suppress%20error%20messages) command with some IF THEN commands to continue using the other control points.

---

<div class="post-metadata">

**Author:** ![KlartRu](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@KlartRu](https://forums.unrealengine.com/u/KlartRu)\
**Post date:** [June 6, 2024, 7:53am UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892/3 "2024-06-06T07:53:39Z")

</div>

My script looks like this

```auto
%RealityCaptureExe% -newScene ^
		-set "appQuitOnReset=true" ^
		-set "appQuitOnError=true" ^

```

and I end up getting stuck here:

 ![grafik](https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/1/9/919fa624abd4263a2860304c7a690fe195024ce6.jpeg)

I have to close the pop up manually and close RC, so that my script turns to the next dataset.  
Any idea how I can force it to quit?

---

<div class="post-metadata">

**Author:** ![OndrejTrhan](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ondrejtrhan/32/906565_2.png) [@OndrejTrhan](https://forums.unrealengine.com/u/OndrejTrhan)\
**Post date:** [June 6, 2024, 8:27am UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892/4 "2024-06-06T08:27:47Z")

</div>

Hi,  
I tested also your script and for me it worked. Can you provide the application reset ([Reset RealityCapture](https://forums.unrealengine.com/t/reset-realitycapture/1520110)) and then try to use the script again?  
Which version of RealityCapture are you using?

---

<div class="post-metadata">

**Author:** ![KlartRu](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@KlartRu](https://forums.unrealengine.com/u/KlartRu)\
**Post date:** [June 10, 2024, 1:36pm UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892/5 "2024-06-10T13:36:22Z")

</div>

That brought me to the solution. I loaded the global settings which reset my =true statement.  
After changing the order everything works as expected. Thanks a lot.

---

<div class="post-metadata">

**Author:** ![system](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/1/3/713c9d3f58553f0de89543d76a8a3a2779dc9fa4.png) [@system](https://forums.unrealengine.com/u/system)\
**Post date:** [July 10, 2024, 1:37pm UTC](https://forums.unrealengine.com/t/not-shutting-down-after-error-occured/1876892/6 "2024-07-10T13:37:03Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
