Unable to create activity builder for Main.xaml. Reason was No matching constructor found on type System.Activities

Hi All,

I have have recently installed Custom Packages build by out client in one of my projects. Since then i m getting below error during Compiling. Unexpected error has occurred during the library compilation process. I have checked the targeting .Net version and package dependencies everything seems good but getting error as below

Unable to create activity builder for Main.xaml. Reason was ‘No matching constructor found on type ‘System.Activities.Activity’. You can use the Arguments or FactoryMethod directives to construct this type. No default constructor found for type ‘System.Activities.Activity’. You can use the Arguments or FactoryMethod directives to construct this type.’.

Could anyone help on this please?

Help > Studio custom-activities

  • List item

Hi @Aswini
As per my knowledge .
ensure that all required properties for the activity are correctly set. If using a custom activity, check that it has a proper constructor defined. Rebuilding the project can also help fix compilation issues. Additionally, make sure all UiPath packages are up to date to avoid compatibility problems. Running the workflow in debug mode may help identify specific issues causing the error.

Happy automation

@Aswini,

Check out this solution

Iam unable to execute the BOT as its failing during compiling

Hi @Aswini

verify that all arguments and properties in Claims Process\seq_AddItems ToQueue.xaml are correctly defined. Check for any missing or misconfigured custom activities.

Ensure all dependencies are installed and up-to-date in Manage Packages. If using custom activities, ensure correct constructors are used with Arguments or FactoryMethod directives.

Mark as a solution , if you found it helpful.

How can i check If correct constructors are used with Arguments or FactoryMethod directives?

@Aswini

can you check in imports if you see any errors ..

cheers