Invoke Code to read excel - VB Net error

Im trying to use VB net code to read a large excel & filter based on a condition.
Below is the code I have used & Im getting the error as -

RemoteException wrapping System.ArgumentException: No compiled code to run
error BC31051: Namespace or type ‘System.ComponentModel’ has already been imported. At line -4
error BC31051: Namespace or type ‘System.Xml.Serialization’ has already been imported. At line -3

at UiPath.Activities.System.Utilities.InvokeCode.RoslynCompilerRunner.Compile(String code,
Int32 errLineOffset,
Boolean generateInMemory)
at UiPath.Activities.System.Utilities.InvokeCode.CompilerRunner…ctor(String code,
String className,
String methodName,
Int32 errLineOffset,
Boolean generateInMemory)
at UiPath.Activities.System.Utilities.InvokeCode.RoslynCompilerRunner…ctor(String code,
String className,
String methodName,
Int32 errLineOffset,
Boolean generateInMemory)
at UiPath.Activities.System.Utilities.InvokeCode.VBCompilerRunner…ctor(String code,
String className,
String methodName,
Int32 errLineOffset,
Boolean generateInMemory)
at UiPath.Activities.System.Utilities.InvokeCode.VBCodeInvoker.GetCompilerRunner(String code,
String className,
String methodName,
Int32 errLineOffset,
Boolean inMemory)
at UiPath.Activities.System.Utilities.InvokeCode.NetCodeInvoker.GetCompilerRunner(String userCode,
List1 args, String imps, Boolean inMemory) at UiPath.Activities.System.Utilities.InvokeCode.NetCodeInvoker.Run(String userCode, List1 inArgs,
IEnumerable`1 imps,
Object args)
at UiPath.Core.Activities.InvokeCode.Execute(CodeActivityContext context)
at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance,
ActivityExecutor executor,
BookmarkManager bookmarkManager)
at System.Activities.ActivityInstance.Execute(ActivityExecutor executor,
BookmarkManager bookmarkManager)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor,
BookmarkManager bookmarkManager,
Location resultLocation)

Hi @Ana_Patricia ,
You can check this link

Why do not you use activity
In your PC not have Excel applitcation?
You can use activity with workbook
regards

Hi,

In the latest version and Windows legacy project, there seems the issue.
As workaround, how about convert to Windows project as the following post?

Regards,

Im dealing with huge amount of data & excel & workbook activities are failing by saying … Job stopped excecuting with some error code. Thats why Im inclined towards using code to read & filter data

@Ana_Patricia

Why not use excel as db ?

Cheers

I’m trying to use either ODBC or OLEDB with invoke code activity to read in one go. Can you help in idenfying the issue with the code I’m using