Microsoft Dynamics Business Central Development – Technical Deep Dive

As we discussed previously in our introductory blog post Business Central – A Modern Solution That Integrates Easily, Microsoft Business Central is an all in one solution with built-in business integration, providing a single comprehensive solution to meet the needs of your growing business. However, it also comes with some challenges, one challenge that was recently faced and overcome by the Xgrid team was unsupported functionalities in the AL language. However, Business Central allows for the development of extensions using .NET interoperability. As the name suggests, these extensions provide flexibility and scalability to the Business Central solution by allowing for extended and diverse functionalities.

How do Extensions for Dynamics NAV Work?

With NAV Extensions, you can add functionality without changing the standard solution from Microsoft. This has the obvious advantage that major NAV upgrade projects are no longer necessary. Once you are using Extensions, the customizations no longer represent a problem when upgrading to the latest version of the solution.

Extensions for Microsoft Dynamics follow a model where you define the functionality as an addition to existing objects. This is how extensions can modify objects to perform business operations. We can develop multiple extensions so that development concerns are isolated and modularized but there is still a limitation under which these extensions perform that is the challenge.

The Challenge

All the functionalities from Dynamics are inherited to extensions but what if a development use case needs certain functionalities that are beyond the scope of Dynamics?
Here comes the Add-In Development for Business Central to rescue. Which provides a clean way to integrate .NET Framework assemblies to Dynamics NAV Server. This opened a lot of possibilities and eventually helped us drive the development smoothly.

One of the many use cases we had was to leverage Microsoft Active Directory user permissions to perform File Operations (Create/Update/Delete) on a Shared Network Drive. There is no built-in support for Active Directory in Dynamics NAV so we used our home-made .NET assembly which encapsulated all the critical File Operations. The basic setup for such Add-In development is provided below for reference.

Add-In Development – Technical Deep Dive

You can take advantage of .NET Framework interoperability so that Dynamics NAV objects can interact with .NET Framework objects. In your extensions, you can reference .NET Framework assemblies and call their members directly from C/AL code.

For easier understanding, we will develop a custom .NET class library that exposes a single method `CreateFile` which writes `Base64` encoded file to a specified location. Example code is provided below:

Now once you have the compiled DLL available, it’s time for Dynamics NAV .NET Interoperability to play its part.

Integrating .NET interoperability consists of the following three steps which are discussed in detail below:

1. Declaring the Assembly

To integrate .NET interoperability, the AL compiler needs to be pointed to the custom .NET assemblies. By default, the AL compiler is only pointed to the location of the default .NET assemblies. You need to explore the `settings.json` file and add your assembly path.

After the reference directory is added in `settings.json` you must declare the type in a `dotnet` construct provided by AL Language, and then reference it from code using the DotNet Variable type.

2. Execute members from .NET Assembly

After `dotnet` reference is created in AL, It’s time we can utilize the functionalities provided by our home-made assembly. We now need to create a `codeunit` which exposes an AL procedure

3. Publishing the extension

You now have everything in place, Just build the extension and you are almost ready to deploy the extension to your production environment.

When publishing an extension, the server will recompile code and try to resolve all the references to external assemblies. The compilation will only succeed if the server can locate and load all the referenced assemblies and types. Therefore, it is recommended to keep the same path for custom assembly on the development and Production business central environments.

Key Takeaways

Dynamics Nav has been helping customers improve their businesses by providing valuable insights. At Xgrid, it helped us expand the existing functionality through customization by adding more functionality using business central extensions. Microsoft Dynamics has a variety of features to boost productivity and is a fast, easy to use, and reliable solution to improve the overall efficiency of the business. Microsoft Dynamics improved forecasting, scheduling, management, and scalability with all other integrated applications. 

With business logic in its DNA business central has made many businesses survive making it a broad and deep functionality that runs thousands of companies all over the globe. To evolve and progress all contemporary business models should shift towards Business Central’s up-to-date solutions.

Read more

Sales Enablement 101

Let’s set the scene. Your company has just launched a disruptive networking solution that is set to shake up the industry. Big names like Apple and Facebook are showing genuine interest and can’t wait to get their hands on it. There’s a lot of buzz around the entire affair. They want to see the product run their specific use cases so they can be sure it fits their requirements. However, it takes you a couple of weeks to set up the entire thing end-to-end to demonstrate one use case. Your competitors have a similar solution and a much faster turnaround time, and they gain the upper hand. The customer goes with them instead and the sale is gone.

One of the biggest challenges businesses face, especially with products requiring a tedious and complex setup procedure, is effectively managing and completing a customer sale. In this case, bringing a potential customer on board, understanding their set of requirements, and setting up a demo or Proof of Concept (POC); all of this would usually take days if not weeks and runs the risk of your potential customer being poached by your competitors. 

What can you do to reduce the time for your overall process? The answer is a Sales Enablement Tool. Since the deployment time of an end-to-end actual physical setup can’t really be reduced, the best way to make the process faster would be having an application or tool that can emulate the customer’s use case. A Sales Enablement Tool or a Sandbox can allow your customers to experience the feature set that your product offers in a customized, tailored environment. Most companies either lack the resources or have a large amount of corporate red tape which prevents them from developing a Sales Enablement Tool for their product. This is where Team Xgrid enters the equation to provide our expert services in developing a fully customized sandbox environment for your product. However, before discussing what Xgrid can do for you, let’s first briefly talk more about the value a sales enablement tool can add to your business.

What is a Sales Enablement Tool anyways and why do I need one?

As the name suggests, a sales enablement tool is designed to empower the sales and marketing team. It gives them incredible versatility in adapting to their customers’ requirements and allowing them to create a more interactive, highly dynamic, and effective sales process. A test run of the actual product, the tool is designed to supplement the product, with the aim of simplifying, streamlining, and accelerating the actions required to set up a POC, as well as making it easily repeatable. All of these are vital when it comes to gaining the upper hand on your market competitors and ensuring your product’s success.

The key factor in all of this is time. The quicker the turnover time, the easier it is for sales reps to iterate and engage with customers. Setting up a blockchain network across multiple physical servers can take hours or even days depending on its scale and complexity. Replacing the same setup with an automation framework that brings up the network in a containerized environment on a single server would cut the time down to a fraction, while also maintaining the integrity and accuracy of the use case.

The flexible nature of such sandboxing tools enables teams to use them for training purposes as well. Think of demonstrating a single POC or use case at scale. The same concerns still stand, more so in this case because more people are involved. Having a tool that can spin up the required scenario quickly and reliably means more people can be trained on that product. More trained people means a larger sales force, resulting in wider customer outreach and, consequently, greater visibility for the business. The perfect chain reaction.

Customized POC Tools provide the added advantage of being inherently virtualized, and hence enable marketing teams to easily demonstrate their solutions online. This is something that is imperative to have, given the way the world works today, and all the more given the ongoing COVID-19 pandemic.

How does Xgrid fit in?

Now that you’re all aboard the hype train, where can one get such an application made for them? One word – Xgrid.

It is essential that sales enablement and POC tools are tailored to the exact requirements of the product. They need to capture and convey the products selling points effectively and efficiently.  That fact is our number one priority when building out these applications. We engage with clients to understand their product and what they want to demonstrate in their bespoke sandboxing environment. Every tool is tailored to support customer-specific use cases and requirements to ensure that the resulting solution is the best fit for you. Our extensive industry experience provides expertise in end-to-end tool design, development, delivery, and support for customers to provide a unique experience in every sales interaction.

Our portfolio includes the development of a tailor-made POC solution for a Fortune 100 company, which enabled them to easily demonstrate their unique SD-WAN solution in customer meetings, in-house training, and global live events. The sandboxing solution allowed their sales team to test out platform releases quickly and bring up client requests and use cases efficiently. 

It has a simple drag-and-drop based user interface (UI), where users can create their network topologies with complete freedom. The deployment process is where all the magic happens. Large, complex configurations consisting of up to 50 network devices spread across multiple physical servers are deployed automatically and managed completely by the application without any user intervention, all thanks to the robust and exhaustive automation framework driving the application. Users can also edit their configurations, tear them down completely and start from scratch, and save existing topologies that the tool can deploy repeatedly, with a few simple clicks on the UI.

Sounds too good to be true, doesn’t it? That’s the beauty of it. It streamlines the entire process to a tee and makes you wonder why you didn’t have a sandbox environment complementing your product in the first place. Sales enablement tools offer incredible versatility and should be a part of every product’s marketing strategy.

Still don’t believe us? Take our community’s word for it. Xgrid was the recipient of the Best in ICT Services award in 2019 from P@SHA (a body consisting of IT companies and industry leaders from across the country) for the Sales Enablement solution we built, which further reiterates the advantages sandboxing solutions have to offer.

Start your journey with Xgrid to experience the wonders of Sales Enablement & Sandboxing for your business. Request a Demo today and let us drive your business drive forward.

Read more

Business Central – A Modern Solution That Integrates Easily

Are you planning to expand your business, but your current technology does not support it? Do you intend to integrate all your current operations, running apps, data, and people into one platform? Microsoft’s Business Central provides unparalleled flexibility with a well-defined path for businesses that are ready to evolve and grow.

Previously known as Dynamics Navision, Business Central is a mid-market, all in one solution with built-in business integration, providing a single comprehensive solution to meet the needs of your growing business. Microsoft Dynamics 365 is an integrated ERP solution that automatically pulls systems and processes together to manage financial sales, services and operations. It also helps in connecting with multiple third-party applications like payroll, CRM, or other industry-specific systems. This management solution helps organizations streamline their processes including fixed assets, orders processing, inventory, human resources, sales & services, project management and manufacturing. In addition to simplifying management, Business Central solution helps users evaluate project performance. Power BI dashboards and charts provide actionable insights to make faster, informed decisions and the ability to accurately forecast the future of your business.  

Microsoft Dynamics enables businesses to develop custom solutions that are easy to configure along with a wide range of functional features. It is the go-to choice for businesses that want minimal configuration, combined with ease-of-use to generally improve business processes and deliver a modern, scalable, and future-proof solution.

What does Business Central bring with itself?

Business Central is fast to implement, easy to configure in product design, development, implementation, and usability. This flexibility allows users to use Business Central with either cloud or on-premise datacenter, depending upon their use case. It offers a great user experience that is consistent across Windows, Android, and iOS devices helping you run your business anywhere. Business Central offers multilanguage support giving the flexibility to view the application in the language of their choice. The availability of multiple languages from all around the world has been assisting businesses. This country-based classification of Business Central provides functionality that has been adapted towards a particular country’s market requirements.

Microsoft data center provides encryption that helps users protect their data from unauthorized access maintaining high standards of security. It also allows users to make informed decisions using connected data to better fulfill the project requirements and reach the optimal level of output. Business Central helps its users to make effective decisions using insights on project’s current status, and resource-usage metrics.

Using MS Dynamics 365 Business Central for App Development at Xgrid

With Dynamics 365 Business Central revolutionizing the ways of doing businesses, team Xgrid adapted this solution for managing multiple jobs and different tasks assignments to enhance the functionality of the construction application for a notable customer. The purpose of this app is to provide a central control to the manager while assigning tasks to the on-site team. It provides a full visibility of on-site tasks and helps in the better management of operations. The solution has a desktop version coupled with an iPad application, to lubricate field task management, resource allocation and bridge the communication gap between the off-field managers and on-site employees effectively. 

These applications along with a legacy SQL server based database use an enhanced business management capability. For the dynamic management of offsite projects, we used Microsoft Dynamics Business Central (on-premises) version to extract and store the data from web applications and legacy databases. The solution leveraged the dynamic capabilities of web services to offer data-rich, cognitive services.

Business Central provides flexibility to customize the applications which allowed us to extend the existing functionality of Job Management module in the construction application. This led us to get the on-premise functionality with robust ERP functionality across the job management module for the construction app. We developed our extension on top of the application to meet our client’s business needs. Our developed extension connected the Business Central web services to the API layer of our solution. This acted as a middleware between the database and the front-ends of the application. Through Dynamics Business Central Web Services, the application users can view real-time data that helps them in dynamic management of their off-site projects. All workers, contractors, and suppliers are now able to perform their tasks keeping each crew member informed and updated all the time.

The second module was to schedule periodic data processing by configuring Job Queues in Business Central. These jobs continuously synced data to and from legacy databases. One of key usage of Business Central in the complete solution was to bridge legacy solutions with a range of mobile devices like iPhone, iPad and Windows client for day to day user activities. 

Dynamics Business Central helps businesses to streamline their application processes and present logical data as per user needs for consumption by the Desktop and Mobile applications. The solution also employed the resource module and enhanced the functionality to provide users with the requested material for a specific job. This further enabled the procurement department to generate purchase orders based on requested materials from different job locations. The ability to have data in real time helps the decision makers to make timely decisions without a need for data migration to transition to this robust platform.

Read more

Evolution of Full Stack Application Development

Software development cultures and practices evolve with the developers’ habitual learning and self-improvement. For a software engineer, […]

Read more

Navigating the software world during COVID-19

Amid the global COVID-19 catastrophe, the worldwide economic downfall brings us all to think where do we stand as a business? For many, it still is a black swan event. The series of unprecedented events makes people from all spheres to evaluate their organizations. Everyone wants to survive and thrive in this pandemic. And the IT industry is no exception. In this blogpost, we will take a look at how the smart use of technology can combat the torment inflicted by the coronavirus.

In this new era of socially distant communities, emphasis is being laid on the use of online platforms and services to meet business goals. Today, hosting the mission-critical resources on cloud is more vital than ever which, according to the Flexera 2020 State of the Cloud Report, has led to a rise in the usage of cloud platforms. It has enabled companies to operate seamlessly by making their services always available without having to physically manage the infrastructure. This way the businesses can focus on their core product and service offerings without having to worry about the infrastructure maintenance. Leveraging on our rich experience of providing end-to-end cloud solutions, we at Xgrid, are helping our clients in designing, developing, and deploying specialized cloud and DevOps solutions that can help them meet the increasing demands of their business needs.

“Xgrid’s wide range of technical expertise with different cloud platforms and orchestration technologies enables the team to provide automation of a wide variety of infrastructure and network resources, and consequently help optimize customer workflows and processes. The current demand for IT services is at an all-time high and will remain so for the foreseeable future. Xgrid plans to assist its customers to the best of its abilities during this time and maintain its excellence and growth in the IT sector.”

Nabeel Afzal, Director Solutions Engineering

Xgrid also bagged a Gold in ICT Services Solutions category in P@SHA Awards held in 2019. The award was based on a sales enablement and sandboxing solution developed for a Fortune 50 company, that allows their sales team to provision remote demos and training environments for their clients. Click here to read more about it.

With work from home emerging as a prevalent mode of work across the globe, online traffic has surged creating a clear need for a resilient cloud infrastructure. The use of social media platforms has increased drastically for networking purposes. Considering this, marketers are planning to revisit their marketing plans. According to the Interactive Advertising Bureau, 41% of marketers plan to change their cause-related marketing strategy as a result of COVID-19. While we are on this subject, the marketing automation and analytics tools such as Hubspot, Marketo, Google Analytics, etc. are helping organizations build smart marketing strategies. Due to increased revenues and flexibility provided by these tools to businesses, you can count on digital marketing platforms for a long-term investment. If you are still not a part of the golden mine of lead generation then, now is a valuable time to drive for change.

“With people glued to screens, now more than ever, digital marketing has become an absolutely essential part of the proceedings. Not to mention, a big boost in creative opportunities for remote working. Start today, start small, and think big!”

Hussain Ali Zaheer, Senior Interaction Designer

However, for both small and big enterprises to greatly benefit from digital marketing, it is imperative that the visual content used is catchy and grabs the attention of the prospective customers in the digital space. Getting the message across with a combination of image, colors and captions is not enough, it is also important to reflect the brand’s organic identity. To make a sale in this pandemic when consumers are more picky than ever, it is important to convey a thought-provoking message highlighting the value your product offers intelligently. Team Xgrid is helping customers boost their sales growth by providing a mix of creative strategy, out of the box ideas and distinct designs.

“For us, design is communication and, to convey a message, proficient designers choose the right visual elements.”

Sher Afgan, Senior Interaction Designer

With the pandemic, the digital transformation has also taken over the world. If you are reading this blog and you have a distinctive idea on how to digitize your product, this is a great time to give your idea a shot.

You can dig deep and come up with remote and hardware-come-software based solutions. If you have any brand new app development idea then hit it off. It is the prime time when from all the social media applications, to entertainment sites like Netflix, e-commerce apps such as Amazon, educational platforms and video conferencing tools like Zoom and Skype are getting a lasting lift. Xgrid has been a part of this trending game since long, delivering iOS and android based cross-platform applications to its customers. Our service offering is not only limited to mobile app development but we also follow a ground up approach to built user centric UIs.

“While the pandemic itself has been a challenge, it has provided organizations such as ours an opportunity to grow culturally while at the same time giving us extended business opportunities. Considering all these factors, we anticipate our MarCom & UIUX work to grow over the next few months as the tech world is clear on the relevance and the effectiveness of remote working.”

Waqas Khalil, Director MarCom & Design

While the crisis may bring some challenges, we all can take this time to reimagine how to reorganize our businesses intelligently to maximize the overall outcome. Working remotely is clearly the new normal and that in-turn opens up opportunities for global collaboration, one that we have never seen before. This is the right time to identify growth strategies and make use of them by involving key players to stay ahead of the game!

Read more

Reusability Is the Name of the Game

Building a large scale iOS application from scratch without any plan in place may have you end up with creating a complex application tied with an unwieldy overtime. Some developers are fortunate enough to find their answers online on sites like Stack Overflow and Hacking with Swift, etc. However, if the app is aimed at being multi-featured, there are only a handful of other apps that can be compared to your use case in terms of scale. The size of such a project file alone takes its toll on your machine, not to mention the build time and overall workload.

So, what’s the solution to this predicament? This is where you need to work smart. Don’t develop unnecessary components! When it comes to auxiliary components like a modal that can be used to add images or notes, a drop-down menu providing the user with various actions, a pop-up with a collection of options out of which you can have multiple selections or other similar components – it’s better to make them reusable. Multiple features of your application will use them so treat them as such by making them generic without any concern for a specific feature’s visual model. Here are a few examples depicting the use of such generic reusable components in example applications:

Reusability in itself is a broad term and may mean something entirely different to different developers. In this article, reusability refers to a concept in application development in which, where possible, you design components that are reusable and customizable, thereby, future-proofing your code.

In order to make a reusable component whose bare-bones structure may be used across multiple apps as well as across multiple features within a single app, you have to map out and design the structure of your component before starting the actual implementation in such a way that if in the future, the need arises, you can customize the component further and add more options depending upon the particular use case.

Let’s take a look at an example of an app in which the user can upload the pre and post images of their room transformation. For this, a custom UIView called AttachmentsListView has been created. This can be used as a component in any controller. In this example app, AttachmentsListView is used in the following two ways:

  1. Pre-transformation
    • Workflow: Clicking on the Add Image button opens up a pop-up modal. The user is required to upload images from the modal.
    • Implementation: For this purpose AttachmentsListView is embedded within this modal. To communicate between the modal and then calling the view controller, a delegate can be used.
  2. Post-transformation
    • Workflow: Clicking on Add Attachment opens up a context-menu to choose from the relevant option.
    • Implementation: The custom view has been embedded in the screen so the user can directly add images or other files.

You might have observed that the scope of attachments has been extended from just allowing the images to be uploaded in pre-transformation section to allowing the user to upload all kinds of attachments such as DOCX, PDF, etc. for post-transformation. This is where the concept of reusability comes into play. All you have to do is add just another AttachmentsListView to allow uploading these files. And for this particular option, you can replace the text of the button from Add Image to Add Attachment by adding a simple check of supportedTypes.contains(.file)

For the context menu, AttachmentsListView contains a UICollectionView section. This collection view further contains two different types of cells:

  1. One that contains a button which opens up a context menu with available upload options for the user to choose from. This can either be:
    • Open camera
    • Choose from Gallery
    • Choose from Files
  2. The other which represents a thumbnail of the attachment

What we see above is the initialization of the function supportedTypes, and the values in this array are further specified in their relevant calling class.

In this example, the user can upload files only for the post-transformation section, hence reusing the context menu with various options as per the use case.

As the above example illustrates, the reusable component AttachmentsListView has been used in 3 similar yet slightly different ways in this one project. It’s not hard to imagine that another app may also need a view that allows users to upload images/files, so it can be reused there as well and can be further customized depending upon the particular use case. Want to dig into the code part? Click here to access the source files on GitHub.

While this solution may look pretty simple, but the fact is, it is important to be able to identify the basic structures that can be used over and over again. Doing so, will prevent the developers from entangling themselves in the web of endless possibilities of defining what components can go generic, and be specific in identifying these components. All major websites and apps across the world take advantage of this concept of reusability to save development time and effort and reduce redundancy in code as well. This not only ensures that their code is efficient but also decreases file sizes and build times overall by having premade components that can be reused throughout the app.

Read more

Why & When to Go Serverless

Serverless Applications and Serverless Computing are some of the terms that you will come across frequently when trying to choose from  various options being offered by cloud service providers like Amazon Web Services (AWS) and Microsoft Azure (Azure). The term serverless accompanied with the word application could be confusing, as it is contradictory to the conventional methods of developing and deploying applications. In this blogpost, we will attempt to explain what serverless applications are and what exciting benefits they bring to the world of cloud technologies.

Serverless applications are built using the services provided by cloud service providers like AWS or Azure, without having the developer to worry about the underlying infrastructure. The core of serverless applications is made from cloud-native services such as AWS Lambda or Azure Functions, which offer Functions as a Service (FaaS). These services provide the ability to write event driven code functions in any of the supported languages. The functions are executed automatically when the associated events are triggered, creating an automated chain of events which can range from an API being called, uploading a file to the cloud or even invoking other serverless functions.

Serverless is the fastest-growing cloud service model right now, with an annual growth rate of 75%.

Source: RightScale’s 2018 State of the Cloud report.

One might wonder what benefits serverless applications provide or why are they getting so much traction these days. The answer to that question is in the pricing model of all of these services which is based on the philosophy that you only have to pay for what you use. Let’s consider Lambda as an example, the price of using Lambda is primarily based on how many times a function is triggered along with some other factors like the function execution time and the resources it utilizes. In contrast to non serverless services that are charged by the number of hours the service was up for.

If a business or developer runs an application on an instance or virtual machine hosted by a service that charges by the hour, they would essentially get charged for the total uptime of the instance, irrespective of whether there are any users using the application or not. If the same application is deployed using serverless services, it will be available all the time, but the account will only be charged whenever an end-user makes a request or uses the application.

Serverless architectures can be very effective for use cases where you want an application that is always up and available, but does not have continuous and constant incoming requests. The application can have a large number of incoming requests at certain times and then have large periods of stagnation with little activity. Other than that, asynchronous or event based tasks like CI/CD pipelines, multimedia processing, and scheduled batch jobs are well suited for  serverless model. A couple of other benefits tied to adopting the serverless computing approach are mentioned in the figure below:

While serverless applications are bundled with various benefits, it is important to understand their core limitations that are often tied to the type use-cases and application models. From the pricing model of serverless services, it is pretty obvious that if the incoming events are large in number you would get charged more based on every input trigger. Services like Lambda or FaaS have  limitations such as the amount of available RAM and accessible disk space  being fixed for a Lambda function. Hosted functions also suffer from an issue known as Cold Starts, which means that every time a function has been dormant for a while it will take more time to spin up on the next request and thus cause a slight performance penalty. This issue can be minimized by using a runtime which suffers less from the cold-start penalty like Python or Node.js. It can also be minimized by reducing the overall function size.

Cloud computing also brings some limitations for serverless applications like vendor lock-in, where the switching cost to a different vendor is pretty high. If you are building a serverless application, you are committing to a specific cloud service provider and building your application around their infrastructure making switching across-platforms very difficult.

With all things considered, serverless is an interesting and in many cases a beneficial approach to building applications on the cloud efficiently in an agile manner, without worrying about managing the underlying infrastructure. It provides additional choices to solution architects while designing application architectures with minimal cost implications for their organizations.

Read more