Error "Object reference not set to an instance of an object" keep appearing

Hi!, I feel like after I updating my Studio, there’s an error occasionally pop up says “Object reference not set to an instance of an object”

I copied the error message to clipboard. here it is.
23.6.1-beta.13324+Branch.release-v23.6.1.Sha.52787b786620e97cba5555379da6e6bb423b3e6b

Object reference not set to an instance of an object.

Error: System.Exception: Object reference not set to an instance of an object.
at System.Activities.Presentation.Validation.ValidationService.MarkParents(ValidationError validationError, IEnumerable1 errorParents, ModelItem source) at System.Activities.Presentation.Validation.ValidationService.MarkError(ValidationError validationError, List1 errorSourcePath, ModelItem source)
at System.Activities.Presentation.Validation.ValidationService.MarkErrors(ICollection1 errors, ValidationReason reason, Activity rootActivity) at System.Activities.Presentation.Validation.ValidationService.OnValidationWorkCompleted(Tuple3 input)
at System.Activities.Presentation.Validation.BackgroundValidationSynchronizer`1.<>c__DisplayClass26_0.b__0()
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler), HResult -2147467261

other than that there’s no syntax error, I can’t debug neither analyze file.
I’m not sure what to do, pls help

@ibnu.alem
Remove the for each and give again

@ibnu.alem

Please check the variables and arguments have passed properly or not

regards

which one and why tho?

@ibnu.alem

Hi,

If myVariable IsNot Nothing Then
’ Perform operations using myVariable
Else
’ Handle the case when myVariable is null
End If

Thanks

any tips to check which activity?

the bot can’t even run or debug. it gets stuck on project validation

@ibnu.alem

Immediatelt after you start are you getting this or is it on any activity?

If it is on activity then check the variables in it…

If it is immediately after you start then please create a nee xaml and leaving out the outer sequrnce copy evry other activity to new xaml and check if the issue resolves

Cheers

@ibnu.alem

If you are using the invoke workflow activities then first check in that and later if the problem is not resolved yet then check the for each UI Element activity whether the data is correctly passed into it.

Regards

@ibnu.alem

Try to restart the UiPath studio and then use for each ui element

yes I getting this pop up randomly, whatever I do. this pop up start randomly came after I upgraded UiPath. it never happen before and I believe I didn’t change anything after update to make this pop up happen.

ok, good to try because it happen on some of my project but not all

@ibnu.alem

It might be because of some missing references…try changing the sequences to new xamls and check

Also a upgrade of system activities might help

Cheers

it still gives me pop up right after i copied the sequence to new xaml.
also my system dependencies is the latest version

actually the for each ui element have nothing to do with this. I just doing some random thing like inputing any activity until the error pop up so I can take a screenshot. also I did restart UiPath and my computer, didn’t help

the for each activity you see just a random activity I input just to trigger the error pop up so I can take the screenshot. the error randomly pop up when I do something so it has nothing to do with the error

@ibnu.alem

Please dont copy the outsequence…copy only the activities inside it…looks like your out sequence is having some issue

Cheers

Hi! I uninstall the studio and reinstall the version before the update and the problem is gone. But I’m using Community edition which is auto updating after some time, and the random pop up problem is back. So, it looks like the studio version did it. any thought?

Hi,

Have to tried analyze project? It will provide you potential issues.

the pop up even sabotages me to do that and debug/run.

@ibnu.alem

looks like your project is not updating…create a new project…copy only the activities leaving the sequences and then use it…

cheers