Showing posts with label Navision Error. Show all posts
Showing posts with label Navision Error. Show all posts

Wednesday, September 19, 2018

Connection Error while launching debugger in NAV

Recently I was working on a project where we have switched the authentication from Windows to NAVUserPassword.

To access different databases and instances we have created different config files and have used them in our shortcut to launch them, everything was working fine but when I try to debug an issue, I was getting the following error, which complains about the DnsIdentity

SNAGHTMLd9b5b4

The key is when  you launch the debugger it uses the config file (ClientUserSettings.config.) located at C:\Users\YourUserName\AppData\Roaming\Microsoft\Microsoft Dynamics NAV\70 and depending on the version you are on it would be 80 or 90 folder. It does not use your custom config files you have created to launch the application.

So, you need to make sure this file is also updated with proper authentication using the ClientServicesCredential which should be NAVUserPassword if you are using UserName/Password. In my case everything was set properly except the DnsIdentity Property value which is blank.

Once I updated the DnsIdentity Value with proper subject name which is the CN name , the debugger started without any issues.

For more information about DnsIdentity and Certificates please check the following link

https://docs.microsoft.com/en-us/dynamics-nav/how-to--configure-authentication-of-microsoft-dynamics-nav-web-client-users

Share:

Thursday, January 4, 2018

Could not Load file or Assembly error after applying Cumulative Update

road-sign-1274312_1920

Last week I have applied the Cumulative Update 50 for NAV 2013 R2 on my local machine.  After I have applied the Cumulative Update I have tried to open NAV Administration Tool to restart the NAV Services but I have encountered the below error

image

The tool was not able to open the management dll , so I have browse to the service folder and reviewed the properties of Microsoft.Dynamics.Nav.Management.dll and found that it was blocked.

To unblock the dll I have clicked the Unblock check mark as shown in the below fig. and then tried to open the NAV Administration tool which then opened without any issues

If you get could not load file or assembly, be sure to check the properties of the file.


image

If you have any other tips or suggestions, please do share them in the comments below.

Share:

Friday, September 29, 2017

MAPI is not working properly while sending email in NAV

Recently I have worked on a issue related to E-mail, and would like to share the solution which helped me to resolve the issue.

One user is are getting the following error “MAPI is not working properly. One way to get MAPI working is to install Microsoft Exchange” when they try to send the email. This is version NAV 2009 R2, and in this version one way to send a report by email is using, File –> Send –> Report by Email. as show in Fig 1.

When I have searched the web I have found articles/forums where it was suggested to unregister MAPI OCX Dll File and Register it again, I have performed those steps but still it did not help to resolve the issue.


image

Fig 1.

One thing I did notice on that workstation was even though Outlook 2013 was installed it was never setup/initialized, once I have setup an account on outlook and then try to send the report by Email it opened the Outlook Client with Report body.

So, please make sure there is a default MAPI email client installed and setup when you receive the above error and that resolved the issue in my case.

If you have any other tips or suggestions to resolve this error, please do share them in the comments below.

Share:

Saturday, August 26, 2017

Could not load xp_ndo.dll Error while accessing Navision

On the other day, I have created a new NAV database (2009 R2) using the SQL backup and when I try to access the database using the NAV client the following error popped up


image


It is more common that we all come across this error some day or the other. There are several blogs demonstrating how to resolve this error. You can find one in the link below

https://blogs.msdn.microsoft.com/nav_developer/2008/11/05/basic-sql-creating-extended-stored-procedure-xp_ndo-dll/

But even after doing the setup I ran into the following


image


The reason behind it was that there exists two xp_ndo dll’s that are named xp_ndo and xp_ndo_x64. One should use xp_ndo_x64 for the 64 bit. So, I changed the reference in the stored procedure to xp_ndo_x64 but still encountered the same error. The solution is to always have the reference say xp_ndo. Therefore, I renamed xp_ndo to xp_ndo_x32 and xp_ndo_x64 to xp_ndo, and then I changed the reference in the stored procedure back to xp_ndo.

If you have any other tips or suggestions to resolve this error, please do share them in the comments below.

Share:

Tuesday, January 17, 2017

You do not have access to Microsoft Dynamics NAV

spanish-761512_1920

image

Most of us must have seen this error when we try to login into NAV, the reason for this error is the user who is logging into NAV does not have access to the database or the user is not setup in NAV RTC.

To fix the above error, you need to setup the user in NAV.  All the steps to create a new user is in the below Url.

https://msdn.microsoft.com/en-us/library/dd355093(v=nav.80).aspx

In another scenario when you have multiple databases and when the user is trying to login into a database, where the user is already setup as user in one of the database but he gets the above error and NAV client closes when he clicks OK.

Let’s assume we have two databases in this scenario TEST and PRODUCTION.

The user who is trying to login, has access to the TEST database but he does not have access to the PRODUCTION database, so in this case the error is valid since the NAV is trying to login into PRODUCTION database by default. But the real issue is NAV does not provide a way to login into TEST database, as it shuts down when you click OK. 

By default which database to connect is stored in a config file called ClientUserSettings.Config file.

In this case to fix the error ,the user need to update the ClientUserSettings.Config file and change the server and server instance key values to point to the TEST database.

The path for the ClientUserSettings.Config file is

C:\Users\<username>\AppData\Local\Microsoft\Microsoft Dynamics NAV

You need to change the below three key values and make sure they point to the TEST Server Instance.

<add key="Server" value="localhost" />
<add key="ServerInstance" value="DynamicsNAV" />
<add key="ServerPort" value="7076" />

Once you change and restart the NAV client it will open it successfully, given that user is setup properly.

Please leave your comments, feedback or any suggestions you have for me to improve my blog and also if you have any questions, feel free to post.

Share:

Wednesday, January 11, 2017

Open Xml Error on preview or print of a report in NAV

printer-98527


Recently I was trying to print a report in NAV 2017 Demo Database, and I have encountered the below error. The same error occurred even on preview of the report.


image


The default report layout setup for the report is set to word , so it is trying to preview or print a word format report . So to answer why does it it need an OpenXml component to print or preview is

In order to generate a word document of the report, the data output of the report which is in XML Format will be transformed by using the .NET Framework components such as Open XML SDK 2.5. Since it is missing that component on my computer, it is giving that warning. Usually you need to install those component on the NAV Server to avoid this error.

There is a nice article on the NAV community blog which explains the whole execution process of a report with different layouts, please check the blog on the below link for more information.

https://blogs.msdn.microsoft.com/nav/2014/10/30/report-execution-insights/

Solution : To fix the above error you need to install OpenXML SDK from the NAV DVD folder Prerequisite Components, once you install the components please restart the services and you will be able to preview or print the report.

Please leave your comments, feedback or any suggestions you have for me to improve my blog and also if you have any questions, feel free to post.

Share:

Saturday, October 22, 2016

Microsoft Dynamics NAV Client has Stopped Working

Last week i encountered an error with Microsoft Dynamics NAV RTC client, whenever i open the client it crashes and gives me the above error message it does not give me an option to reconnect or choose a different service, it just crashes. The error/problem details on that page does not give any information about the error.

Below is the error details i can view from that window.

image

so first thing i did is to check the event viewer and there are two errors reported at that time

1.  Application Error

This has very little information about the error and which is not helpful to debug the issue, the details of the error are something like in the below screenshot

image

2. .NET Runtime

This error has following details

image

If you notice the error is related to SQL Database Sync. Below are the steps i have performed to resolve the error.


1. RESTART NAV SERVICES -  THIS DID NOT FIX THE ISSUE

2. DELETE THE PERSONALIZATION STORE XML – THIS DID NOT FIX THE ISSUE

3. FROM DEVELOPMENT ENVIRONMENT – I RAN Sync. Schema For All Tables

image

This did the trick and resolved my issue.

Please leave your comments, feedback or any suggestions you have for me to improve my blog and also if you have any questions, feel free to post.

Share:

Wednesday, August 12, 2015

The Type of Flowfield in the table must be decimal

 

It is always challenging to resolve an error, when the error message is unclear or misleading.  Today I encountered same kind of message while I was making a modification to the table. 

 

error-63628_1280

I had a Normal custom date field in one of the table , i had also added some logic for validating the field and populating it on certain conditions. But today the requirement has changed and the user wants to convert that field to a Flowfield and to lookup  to another field in a different table. We have some test data in the database where custom date field is populated in initial testing, so the first task when you change type of the field, if you have the data in that field, is to clear/delete the data from all the companies.  Second task is to find the places where you assigned the value for the field and comment/delete it.

After completing the above two tasks I started testing the change and I received the below error

“The type of flowfield xxxx in the xxxx table must be decimal”

The first thing that occurred to me was the “CalcFormulae” might be looking at wrong field so I verified it and everything was fine there, so I compiled all the related tables and pages to check again but I was still getting the error.

I ran the debugger and it is breaking at a line of code where it is trying to validate the field, it is not assigning any value just validating

VALIDATE('xxxxxx');



Once I commented the code, it worked fine. Interesting huh.. I tried with other field type text as flowfield and I got same error message, I tried with decimal field it gave me similar kind of error message.


I understand you cannot validate a flowfield but the error message it is throwing is totally misleading, I am not sure but I believe this is a bug.


If you encounter above message please do check if both tables have same data type and if there is any code to validate the field.

Share:

Friday, December 20, 2013

Thursday, December 19, 2013

Restore failed Operating system returned the error 5 (Access denied)

I was trying to restore a database using SQL 2012 management studio but when I click ok after selecting file I was getting below error

clip_image002

Cause:

By default the database and log files are creating in MSSQL10_50.MSSQLServer folder.

image

Resolution:

Check the Relocation all files to folder  in the above fig. so that it will create files in MSSQL.11.NAVDEMO folder

Share:

Wednesday, December 18, 2013

Saturday, September 29, 2012

"The date is not valid" in Navision 2009 SP1 or R2

Today I got a request in which the client was getting "the date is not valid" error when they are trying to authorize credit card using Navision Webservice. They were using chargelogic add-on and exposed a codeunit in which it has functions to authorize credit card.


When I first saw that error my initial thought was it is something related to settings in customsettings. config file. So we changed "WebServicesDefaultTimeZone” setting to use "Server Time Zone". But unfortunately that did not fix the issue and we kept getting the same error. Then I used my debugging skills to find the part of code where the error was happening. Once I debugged it I found that they have some customizations to improve performance in which one of them was to use single instance codeunit to get data from setup tables. Instead of using normal statement table.GET statement they stored all these get statements in separate functions in a single instance codeunit and they called this codeunit whenever they wanted to use GET statement for setup tables.

Share:

Saturday, July 7, 2012

The Page contains a control add-in that is not permitted.

You may notice this error, when you develop a client add-in and add that to a page but forget to register the client add-in.



In Navision whenever you develop a client add-in you need to register that in Client Add-in” table (2000000069) with at least its name and the public key token of its signature. You can do this manually if you know the public key token and here is the msdn article to get the key for add-in.

Share:

Wednesday, July 4, 2012

An Error has occurred while logging on to the MAPI session - Navision


The other day i was helping a client to move their customizations from classic to Role Tailored Client. They had a custom email functionality which was working fine but when the function was executed in Role Tailored Client Navision 2009 R2 it did not open outlook client. When i debugged i found that error was happening at the below line of code which is in custom codeunit which was implemented by previous VAR.

IF (NOT OApplication.Logon(TRUE,'','',FALSE,FALSE)) THEN BEGIN
  OApplication.Logoff;
  EXIT
END;

 
Then i added Message Box to display OApplication.ErrorDescripton which showed the below error message.


I googled for this error but could not find much help, so i executed standard email function on customer communication and it was working. Then i compared custom function and the standard email function in codeunit 397 for new message. I found one difference, when an object is created using CREATE the custom email function was not using NewServer and OnClient parameter.

For example custom code has : CREATE(OApplication) which will work fine in classic, but to execute this on RTC we need to use NewServer and OnClient paramters.

So i have changed code from CREATE(OApplication) to CREATE(OApplication,TRUE,TRUE) and did this same for other objects. This resolved the issue.


Share:

Tuesday, June 12, 2012

Data migration error %1 is not a supported datatype


When you design a dataport and if you have used a field which is of flowfield type and when you try to import data using that dataport, you will be see the below error message.

"%1 is not a supported datatype"

To reslove this error please remove the flowfields from field designer of dataport.
Share: