Custom Package not seen in activities list

Scenario:

Created a custom package in visual studio from a C# program. Created a nuget package and installed in UiPath activities. The custom activity installs but doesn’t get listed in the activities pane of UiPath Studio

Steps to reproduce:

  1. Created a sample program which uses external dependencies such as iTextSharp, Bytescout, etc.
  2. Built the program, no errors
  3. Created NuGet package using NuGet Package explorer.
  4. Added in Packages folder of UiPath
  5. Installed from Activity Package Manager
  6. Custom Activity Not Seen in Activities pane of UiPath Studio

Current Behavior:

Custom Activity Not Seen in Activities pane of UiPath Studio

Expected Behavior:

Custom Activity should be available for use in UiPath Studio

Studio/Robot/Orchestrator Version:

UiPath Studio Trial 2016.2.6379
Last stable behavior:
Last stable version:
OS Version: Windows 10
Others if Relevant: (workflow, logs, .net version, service pack, etc):

[UiPath.Workflow.Logging.StudioTraceListener] [44] System.BadImageFormatException: Could not load file or assembly ‘ReadingValidBarcodePagesFromPDF, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null’. This assembly was compiled for a different processor.
at System.Reflection.RuntimeAssembly.nLoadFile(String path, Evidence evidence)
at System.Reflection.Assembly.LoadFile(String path)
at UiPath.Project.ActivityPackageManager.LoadAssemblyFile(String filePath)

Seems you’ll need to change build options.

Hi @andrzej.kniola tried changing the buildplatform target for x64 for all the files. Is that what you wanted me to do?

Should all the the custom package be in x86 or x64? or any target will be supported?
Please shed some light on this.

I haven’t encountered this with UiPath Studio, so can’t say for sure.
What I can say is that I haven’t encountered any issues while building for AnyCPU (naming might vary depending on your IDE).
It might also be that one of your other libraries that you’re using for that project is causing the issue.

Can you try building a package that uses only system libraries with same settings and see if it causes an issue?
If it doesn’t, try adding the libraries that you use in this package one by one and see if you can pinpoint which one is it.

Hi Sripadraj,

Did you get any solution for this issue?

I have been facing similar issue.

Kindly let me know if you can provide any solution to this.

Thanks!
Naveen

1 Like

@Naveen, what is the problem you are facing can you attach your C# code.

You need to use two dll System.Activities and System.ComponentModel;

@MahalingPatil Even after including system.componentmodel i am unable to see the activity.

@Naveen That’s not an activity.

For it to be an activity, it needs to inherit from either NativeActivity or CodeActivity (or CodeActivity<T>).

What you have is a class that implements IRegisterMetadata interface (sort of… that actually won’t work).

Please check UiPath’s tutorial/resources and/or their public repos for how to make an activity.

1 Like

Hi,

in your package of NuGet in the option id, is very important set the word “xxx.Activities” once considered the word now you can see you custom package in activities list.

regards .