Tag Archives: Microsoft Dynamics

Dynamics NAV in C# | Part 1 | The Differences

Ok, when you make a promise you have to keep it, so here is the first article around C# and Dynamics NAV.

The story is around my own explorations around C#, Visual Studio and .Net.

Before you start working on C# as a Dynamics NAV developer, or as some call us Dinosaur, you need to be aware of the differences in approach.

Database driven development

In Dynamics NAV we are used to develop in a “database”. This used to be a native “fdb” file in the old days and nowadays it’s a SQL Server database. The development we do is a combination of coding and defining metadata.

More than one developer can work in the same database and we can move parts of our code from one system to another using binary files we call “fob”.

File driven development

When working on a piece of C# code in Visual Studio you’ll probably work in what they call a “project” or “solution”. This is usually a folder somewhere on your drive with a bunch of files. To start working on a solution you have to open the “.sln” file which will give visual studio the information it needs. In the simples scenario where you develop a piece of C# code for Dynamics NAV your solution will have a “.cs” file that contains the actual C# code. You can compare this file to a Code Unit in Dyanamics NAV. Visual Studio will also generate a bunch of other files that you can ignore for now

Compiling

Compiling in Dynamics NAV is called Build in Visual Studio. Both features check the code for errors and generate “stuff”. The stuff in Dynamics NAV is (funny enough) generating the C# from the C/AL and binding it into the other objects. The stuff in Visual Studio is generating the DLL file that you will use in Dynamics NAV as a DotNet library.

Versioning

Both Dynamics NAV and Visual Studio do not offer object versioning by default.

Team Foundation Server

When working together on a larger Visual Studio C# project you can use TFS, or Visual Studio Online to manage tasks and versions of your C# files.

TFS is text based, like Visual Studio and does not understand the structure of Dynamics NAV and its binary objects that are stored in a SQL Server Database.

You can use TFS manually with the Text files you can export from Dynamics NAV, but there is no automatic interface. There are some third party tools that provide help with that.

Let’s get started: “Hello World”

So having explained the differences, let’s start working on a very simple C# project. We will start with a good old “Console Project”.

After having started Visual Studio we will generate a new project like this:

CSharpNAVEx1Image1

And then we get “the list” that confuses most people that get started with Visual Studio and makes you unsure.

CSharpNAVEx1Image2

Lets discuss what we see here

On the right there is a bunch of templates. Ignore everything you see here and only go to Visual C# and Windows. Within this menu we have three types of projects that we will use in this series: Console Application, Windows Forms Application and Class Library. We will now choose “Console Application”.

On top we can choose the version of DotNet we want to use. Dynamics NAV uses 4.5 so we know that our users will have that installed and can go ahead and use this version.

Then we can select a name and location for our project. We choose “Hello World” and leave the folder to default.

On the far right bottom you can see the “golden” option “Add to source control” which will register the solution on TFS or Visual Studio Online system. We will not do that for this example.

The “main” function

When Visual Studio has generated the project we get this window:

CSharpNAVEx1Image3

Let’s talk through them

First we see a bunch of “using” lines. These are the DotNet libraries that will be used by this project, which can be compared by using Code Units in Dynamics NAV that contain functions you use accross the application, if you don’t define the Code Unit you cannot use the function. We’ll get back to that later in the series.

Then we see the namespace of our project. You can compare this to the Add-On number bands in Dynamics NAV, every project or customer get’s their own Namespace. During our series we will not change the namespaces, just leave it as it is.

Within the namespace we see a class. This can be compared to a object in Dynamics NAV, a logical group of code or features. You can put everything in one class like in a Code Unit but that would not be maintainable

Lastly we see what is most important

static void Main(string[] args)

This is a function. It is very important to understand the syntax of a function. Unlike Dynamics NAV where we define functions as metadata we can define functions in C# by just typing in new text. We can break down this line into four parts

static

This defines how the function can be used. We will need this when we start working on DLL files that we use in NAV. Functions can be Static, Public Private. Comparable to using local functions in Dynamics NAV or Single Instance codeunits.

void

This is the return value. Void means no return value. Like Dynamics NAV a function can only have one return value

Main

This is the function name. Main is a reserved name that can be compared with Codeunit 1 in Dynamics NAV. The program starts here and always passes this code.

(string[] args)

These are the parameters of the function. In this case the function accepts an array ([] means array) of strings.

Hello World

Now that we know what we see here we can add some code to our function Main and test if it runs.

Since we have a console application we can write to the console. Lets add these lines:

CSharpNAVEx1Image4

 

Console is a variable we can use like DIALOG in Dynamics NAV. This will display “Hello World” and wait for user input.

Console.ReadKey();

Please note that even though we are not passing values to the ReadKey we still have to provide the (). When you start writing C# this will make you go bananas and if you forget them you get a really weird error like this:

CSharpNAVEx1Image5

So never forget them!

Let’s run the thing alright!

CSharpNAVEx1Image6

This is what you get when you press the Start button.

Congratulations you have just created your very first C# application and learned about a lot of differences between Dynamics NAV and Visual Studio.

 

Convergence 2014 | Strategy Cleanup Time

It has been a while since I did some blogging. In Dynamics NAV we are in between releases and everything about Crete is still under NDA. However, after looking at the Convergence 2014 Keynotes yesterday I felt I needed to write down my opinion about where I think Microsoft is heading with Dynamics.

Disclaimer: This article is written primarily to clear my mind and is only my personal opinion on the market, based on publically available information.

More than a decade ago Microsoft started their ERP aspirations and acquired Great Plains and Navision and started their own CRM application. Back then everyone thought that soon after that the products would merge into one application. But they did not. Until this very day Microsoft is maintaining all products. Or not?

The Convergence event was Great Plains heritage. I visited the event twice in the US back in 2006 and 2007 and the first events in Europe around the same time. Back then Navision and Axapta were big in Europe and Great Plains dominated the US. Great Plains never really made it outside but Navision grew strong in the US competing with Great Plains. With this in mind it was not a surprise that Great Plains got a lot of attention during the keynotes back then, but Microsoft made sure all products got their share.

This has changed. Yesterday I replied on Twitter that I was disappointed about the keynotes of Convergence 2014, but this is not entirely true. The keynotes of Convergence completely shifted towards AX, CRM and a little GP. I guess I was just disappointed that NAV did not get much attention. But this can be explained, but not very easily. Let me give a try.

Yesterday I got an email from a friend with sales numbers of Microsoft Dynamics in the last 12 months. Dynamics NAV was selling better than other products and he was happy. But should he be?

Here are the figures:

Conv   2014

Conv   2013

%   change

Adds/month

Microsoft Dynamics AX

19,000

18,000

5.6%

83

Microsoft Dynamics GP

47,000

43,000

9.3%

333

Microsoft Dynamics NAV

102,000

94,000

8.5%

667

Microsoft Dynamics SL

13,500

13,500

0.0%

0

Microsoft Dynamics CRM

40,000

39,000

2.6%

83

221,500

207,500

6.7%

1167

Source: http://msdynamicsworld.com/story/microsoft-dynamics-gp-and-nav-outperform-ax-and-crm-handily-customer-adds

Now although Microsoft never got around merging the products, what they did do is position them strategically. By doing this they allow individual product development to focus on different target markets while avoiding internal competition. But is this really true and is it working?

I replied to the email with a quick analysis of the figures and I will share this here too.

First of all we are missing a product in this list. A product that Microsoft never really mentioned actively during the last decade but that has become quite interesting in the last year. Microsoft Dynamics C5. Let me try to explain why this product is so important from a strategic perspective.

C5 is a local product that holds a strong position in Denmark, the original market where Navision was invented and the product was inherited by Navision when they acquired Axapta and thus inherited by Microsoft. They kept supporting the legacy software quietly for 10 years until they decided to stop the product. Microsoft Dynamics C5 2014 is actually Microsoft Dynamics NAV 2013 R2 with another splash screen and limited functionality. But that’s not the only difference; even more important is the different pricing. It’s extremely cheap compared to NAV, but limited to 3 users, and only available in Denmark. For now at least.

Let’s remember this and look at the other figures. The next thing that surprised me, and also makes me wonder if the figures are 100% correct, is that SL (Solomon) is not being sold anymore. Although Microsoft supports the product officially, rumors have been that they do not maintain the product themselves, but outsourced it to an external company. Maybe this is why there are no sales data, or maybe it is safe to claim that the product can be declared deceased.

If this is true, it’s interesting to ask the question why Microsoft did not pull the same trick with SL as they did with C5. We’ll let that thought hang for now while we look at GP.

GP is an interesting figure. Reason for that is that like C5, GP is only sold in a local market. North America that is. Realizing this fact, the numbers need to be compared differently to NAV than just one-to-one. They sold, according to this information, 4000 licenses in North America alone which is an impressive figure compared to the 8000 licenses that NAV sells worldwide.

Then we have AX and CRM. Each worth 1000 adds. This seems small compared to the numbers GP and NAV write up together, but from a strategic perspective these 2000 adds are at least equally interesting to Microsoft or maybe even more.

Microsoft has been struggling with both the marketing positioning of the ERP applications and the real world interpretation of this. However it seems that this is clearing up although there is at least one conflict area that needs to be solved.

Last year Microsoft announces that AX is now targeted at the Global 2000 companies. These are large companies like Delta Airlines who was part of the keynotes yesterday. Considering that there are only 2000 Global 2000 companies, 1000 adds theoretically should cover half of that market although I expect not all of the 1000 adds are in this target area.

This positioning pushed AX up which was a big relief for a lot of Dynamics NAV partners who compete internally with AX and takes away part of the pressure these applications had internally.

While AX has been pushed up, NAV has been pushed down. Or at least have been by the marketing department of Microsoft. Also the strategic investments in the products have been implemented accordingly.

The best way to explain this would be to compare technological and functional investments. Microsoft did a huge effort in putting a lot of functionality out of the box in AX making it able to compete with SAP and Oracle while the investments in NAV have been targeted at making it high-tech from a repeatable perspective in cloud scenarios.

So from a marketing perspective this makes a very clean cut between AX and NAV, but this clean cut has yet to be adopted by the real world. And as we all know this takes time and time is something that money can’t buy.

But does the real world work like this, and where does that leave NAV and GP? Let’s try to look at that from a business perspective.

One thing the keynotes had a lot of was how customers are positioned in the current market environment. There was a demo of a guy that lost his credit card in Iceland and the so-called phone operator pretended to be friends with the customer based on CRM data. This customer based thinking is a global trend, but was aggravates me a little is that people pretend this is something new. But it’s not. It’s how people want to be consuming and how we consumed for the last 2000 civilized years except for the last decade. Globalization and computerization allowed companies to get bigger than we could have ever imagined, but this lead to consumers being treated like numbers. We all have experiences with large airline or telecom companies being held on a line when something went wrong outside their standard procedures. This was caused by companies growing outside the size where human relationships were maintainable and the trend is that the internet and social media solves this by empowering the individual voice.

This market environment is what AX and CRM serve in a brilliant way and from that perspective the keynotes were very interesting to watch. For Microsoft it is very appealing to have a strong position in that market area and therefore the 2000 adds that AX and CRM did were more important than the 12000 adds from GP and NAV. From their perspective.

NAV is positioned by Microsoft as a highly repeatable cloud product and this from that perspective extremely interesting for them. Much more than the traditional positioning that NAV used to have. Yesterday Microsoft showed this slide during the general NAV session:

2014-03-05_10-59-43

The SMB market represents 90% of the total businesses and 90% of the employees and the latter are concurrent users from a Microsoft perspective.

Traditionally Dynamics NAV has a strong position in the high end SMB market. This is a segment where companies are small enough to be managed by traditionally one or more owners that had a unique view on their market requiring an ERP package that could support this. Being very easy to customize Dynamics NAV has a strong position in this part of the SMB market.

From a Microsoft perspective this market is less interesting. The reason for this is that most of the revenue at these companies are service revenues and not so much licensing. This is the reason for NAV to reinvent itself as a highly repeatable cloud solution.

However from a partner perspective the traditional NAV market is highly interesting as consultancy rates are a great revenue and customer loyalty can be extremely profitable.

This is where the friction is and where it will be highly interesting to see where the channel will be moving to and also why the investment and positioning of Dynamics C5 is so important.

It is also where GP and NAV start to be overlapping, which will be interesting to watch what will happen internally at Microsoft.

As a European NAV consultant GP was something that happened across the Atlantic. It does not exist in Europe and therefore was not interesting. However the differences between GP and NAV seems to be the same reason for the differences between the European and North American Dynamics markets and this will be a challenge for Microsoft.

During one of the meetings between Microsoft and North American partners many of them complained that the fact that there is little investment in the NAV functional area’s made it hard for them to compete with for example Epicore. I made a statement during that meeting that the responsibility of Microsoft is to deliver a solution that is 80% ready to go to market and partners should deliver the 20%. Microsoft delivers the spine and partners create the body. This is how NAV is sold in Europe. Some partners use that 20% to go vertical and even add more while other partners add horizontal features completing NAV to be used in more traditional trading scenarios. These more traditional scenario’s is where GP in North America is more successful than NAV. Out of the box it has more functionality than NAV but it is sold for the same price. However the underlying technology is not as flexible and high-tech as NAV, but that does not matter if you are not interested in doing customizations.

So my moving Dynamics NAV in a strategic area where cloud repeatability is more important than customizability Microsoft has put themselves in a highly interesting position given the fact that they use the same 80% finished application.

The combination of Twitter and online convergence allows one to almost feel present at the event and one of the tweets yesterday was highly interesting from the point of this analysis.

2014-03-05_10-59-43-1

Microsoft typically holds pretty smart people on their payroll and it would surprise me if internally they would not have made the same analysis I just made. The question however is if adding functionality after the Crete release is not too late.

Competing products already have a strong position in the cloud and by numbers the out-of-the box GP product is outselling NAV in the North American region unless half of the NAV sales are in that area, which with the traditional European focus of NAV would surprise me.

The next two to five years will be highly interesting. From a technological perspective Dynamics NAV in the cloud is next to brilliant. The way it is integrated into .net, azure and PowerShell is next to perfect and beats any other product in the market. However it will only be successful if partners provide the 20% functionality. However, for partners the traditional high-end SMB market is way too valuable to just let go and switch to a completely different cloud based subscription model. It would be easier and make more sense if Microsoft adds the 20% themselves and make the product more cloud ready from a functional perspective. Which then would make an interesting question where that leaves GP? And where does that leave the traditional NAV market share?

Disclaimer: This article is written primarily to clear my mind and is only my personal opinion on the market, based on publically available information.