Skip to main content

#bcopendiscussion - Dummy Extension for Print Custom Report From Purchase Order.

 Hi Readers,

This article is originated from one of our weekly #bcopendiscussion. This article talks about a concept you can enhance this extension the way you wanted. 

I have two other way that I can handle it, so feel free to add your views in the GitHub repo. 

If you find this useful please thanks  Shahid Ullah.

#bcopendiscussion

The discussion question was - 

I like to replace the existing Purchase Order Report with my Developed Purchase Order Report using the below condition-

I have added a filed Order Type and Value is say 1,2,3

If Order Type 1 then like to call Custom PO report ID-50001

If Order Type 2 then like to call Custom PO report ID-50002

If Order Type 3 then like to call Custom PO report ID-50003

Here is how I thought would be simple extension for it -

1. Add a Field in Purchase Header Table and Purchase order Page.

Using Table Extension add a field & using page extension add field in General Tab.

** Just for Demo I am using SDH Prefix/Suffix.


2. Add a Codeunit To Subscribe Event from Table Report Selection.

Check it is purchase order or not. If its not purchase order then exit otherwise call customize report.

3. Add Reports that you need. 

For Demo I just copied base Microsoft Report and saved in 5000 Numbers.

4. Test Process, Check Purchase order and check with Order Type = ''.

5. Test Process, Check Purchase order and check with Order Type = option2.

If you find this useful, or would like to enhance this please feel free to download / contribute using GitHub repo.

GitHub Link - https://github.com/postsaurav/PurchaseOrderPrinting

If you are still in C/AL please download objects from here. OneDrive Link

Source code is developed using Business Central 14. You can branch out and download symbol to test it. When you will try to download symbol system will generate launch.json.

Let me know your views on same.

Regards,
Saurav Dhyani
https://www.sauravdhyani.com/

Comments

Post a Comment

Popular posts from this blog

VIEW SERVER STATE permission on SQL Server?

Hi all, Sometime While trying to Login into a database we face an error message as shown below. --------------------------- Microsoft Dynamics NAV Classic --------------------------- You cannot start Microsoft Dynamics NAV Classic because you do not have the VIEW SERVER STATE permission on SQL Server. Contact your system administrator. --------------------------- OK    ---------------------------

NAV 2013 R2 - Cumulative update 12 Released.

Hi all, Please find below the details of  Cumulative Update 12 released for Microsoft Dynamics NAV 2013 R2. Title - Cumulative Update 12 for Microsoft Dynamics NAV 2013 R2 Build No. - 38053 Release Date - October, 2014 Local Version Included - AU, AT, BE, CH, DE, DK, ES, FI, FR, IS, IT, NA, NL, NO, NZ, SE, UK, RU Download Link Note: Implementing this cumulative update will require a database conversion unless you have already implemented update rollup 5.

NAV 2013 Upgrade Part III - Data Upgrading.

Hi all, As per agenda we need to discuss the data upgrade in NAV 2013. The process is similar to what used to be till NAV 2009 R2 but with some changes. Let's start the process. Remember -  1) You can only upgrade a database to NAV 2013 from NAV 2009 SP1 / R2 SQL Only. 2) The Synchronization of users with SQL Server is no more required.