Skip to main content

Is there any possibility to add Nuget packages to Acumatica Customization project?

Yes, you can add them using normal Visual Studio and incorporate them into the dll for your project.  Is there a specific package you’re looking at?


No, I am going to use it in a new package. Could you please tell me how can I incorporate those into .dll and add it to my project.?


There’s some steps involved and this course goes through the process: https://openuni.acumatica.com/courses/development/t190-development-quick-start-in-customization/.

 

 


@asommer I followed that one and there was a validating error related to Nuget package when I’m trying to publish the project.Is there any special way to add Nuget package into the .dll file?

 

Error is :

CustomizationV1.dll Failed to resolve assembly

Interesting, what Nuget package are you trying to include?


@asommer Its EPPlus Nuget Package.


@charithalakshan49  Not sure about the error, you are getting.

But I just tried and able to install it in my local Acumatica instance through the VS.

 

 


@Naveen Boga Yes, I also was able to add the Nuget package without getting any error. But the error occured when I add some codes in graph using that Nuget package.

 

As an example can you please try adding this code snippet to a graph.

using OfficeOpenXml;

ExcelWorksheet sheet = package.Workbook.Worksheets.Add("MySheet");

 

This leads me to above error when publishing.


Hi, everyone

You can create ignore file (with saved errors) and add it to customization package.

This approach will skip errors and publish customization, but I am not sure that site start working, depends from *.dll from nuget package. I had (successful && !successful) situations.

https://help.acumatica.com/Wiki/(W(27))/ShowWiki.aspx?pageid=282cc58a-4700-4e9d-8cf6-4641e625c0d6

https://stackoverflow.com/questions/48679096/acumatica-unable-to-publish-the-customization-package


@charithalakshan49 when you add a nuget package dependency to your project, usually you’ll get a separate dll corresponding to this nuget package in your bin folder. That dll should be also included in the customization package. Please make sure it’s there.


@Dmitrii Naumov I had a look about that. Yes, the .dll related to Nuget package is there in Bin folder. But in customization project editor, I can not see it when I click Add files. So, how do I add it to my project?

 

 


@charithalakshan49 you can put that dll in the bin folder of your local site and then you’ll have it in this list


@Dmitrii Naumov I added it to the package as you said. But again it shows the following validation errors.

 


@charithalakshan49 it seems this nuget package has other dependencies. You need to add all dependencies to the customization package


@Dmitrii Naumov Adding all the dependencies(I identified those according to validation errors) to customization package solved the validation errors. Thanks a lot.!

 

@andriikravetskyi35 @asommer @Naveen Boga Thanks for the responses.!


Reply