New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please include ZXing or similar DLL for barcode generation #2104

Open
salgiza opened this Issue Apr 30, 2018 · 7 comments

Comments

Projects
None yet
6 participants
@salgiza
Copy link

salgiza commented Apr 30, 2018

I'm aware that we could create an Azure service and call it from NAV (#744), but including barcodes/QRs in reports is something that many customers request, and it seems odd to require an external service + associated costs just to do it, specially when Microsoft could solve it by including ZXing (https://github.com/micjahn/ZXing.Net) and creating a wrapper codeunit so that we could invoke it.

(And, let's be fair, some customers are still a bit reluctant to move to the cloud. Anything that's harder to implement in BC than on premise, it's just another excuse for them to stay on premise)

We've actually done something similar ourselves in the past, and an AL function with this signature:

 Encode(Value: Code[1024], Format: 'AZTEC,CODBAR,CODE39...', Height: Integer, Width: Integer, VAR TempBlob: TEMPORARY Record TempBlob)

Would allow us (partners) to include barcodes in reports, without external costs, and without the need for every partner to reimplement the same code.

I can understand the security implications of adding extra DLLs to Business Central, and that for Microsoft this is not so simple as just including a DLL and call it a day, but I also think that this would greatly help developers, cover a use case that many customers require, and give an edge to BC over other ERPs that don't include this functionality as standard (or compete with others that do include it).

@FSharpCSharp

This comment has been minimized.

Copy link

FSharpCSharp commented Apr 30, 2018

This is indeed a very important issue for the future. From my point of view it would be best if Microsoft could provide an Azure service here itself, or a corresponding DLL on the ServiceTier. To my knowledge Microsoft already uses the Aspose.Word DLL for the PDF conversion. This applies to the standard Word reports. Here is a function to which you pass the path to the original Word document, and you can then convert it to PDF without Word being installed on the server. And in the PDF properties you will find the Aspose library. A customer once drew our attention to this because he thought that Dynamics NAV was here. Instead, a product that was completely new to us at the time was in the document properties. But the Aspose DLL is not stored in the ServiceTier directory, I couldn't find it. I assume that Microsoft has hidden it in some other DLL.

Maybe Microsoft could do the same here, and provide the Aspose.barcode DLL as wrapper, because it supports almost all barcodes available. This belongs either in an Azure service, or in the ServiceTier directories + own wrapper code unit. This would make it very easy to generate and reuse barcodes in the future. Just to give you a little idea.

@erikrijn

This comment has been minimized.

Copy link

erikrijn commented Apr 30, 2018

You could just create a rest service that returns a base64 encoded barcode image. If you can wait a few days, I'd be happy to provide you with a code sample to set up an app service or azure function.

@salgiza

This comment has been minimized.

Copy link

salgiza commented Apr 30, 2018

@erikrijn Thanks a lot for offering an example on how to create such a service, but this ticket is precisely about being able to do it without calling/deploying an external service!

@erikrijn

This comment has been minimized.

Copy link

erikrijn commented Apr 30, 2018

Well Microsoft has been clear from the beginning that additions like this will have to be done using API's. Sure you might find this addition super important, but along comes the next person who needs something else which he/she considers core functionality. And so on, and so on.

@dennisfrostlander

This comment has been minimized.

Copy link
Contributor

dennisfrostlander commented Apr 30, 2018

Thanks for the suggestion. We will have another discussion between the teams on this topic. As it was correctly mentioned, it's not a straightforward process to host a 3rd party DLL on Business Central servers.

@ShadowXVII

This comment has been minimized.

Copy link

ShadowXVII commented Jun 29, 2018

We'd like to see some sort of native Barcode encoding mechanism too. We could use an Azure function, but there'll be a latency involved which would be tricky to work around. E.g. generating unique labels for hundreds of items on an order would take forever to generate the barcodes and bring them back into the system.

@EasyStep2Lean

This comment has been minimized.

Copy link

EasyStep2Lean commented Jun 30, 2018

Agree, Use either Zxing of any other Encoding library, is core functionality in the current ERP world where tracebility is an ever increasing demand, and using barcoding for this is eminent. Latency is also my worry using the Azure functions. Simple wrapper function being able to create barcodes please. You can get our function for free microsoft but I think building one yourself would take your guys max 4 days

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment