Dynamics NAV

Showing posts with label NAVISION. Show all posts
Showing posts with label NAVISION. Show all posts

Monday, 28 November 2016

Internal error: Could not load file or assembly 'Microsoft.Dynamics.Nav.DotNetBridge, Version=8.0.0.0

Some time we may get the below error while import the objects



---------------------------
Microsoft Dynamics NAV Development Environment
---------------------------
Internal error: Could not load file or assembly 'Microsoft.Dynamics.Nav.DotNetBridge, Version=8.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
---------------------------
OK   
---------------------------


Solution.

This is due to  running the client from C\program files (x86) folder which is for 32 bit applications . We should run the dev client from C:\Program Files (x86)\Microsoft Dynamics NAV\80\RoleTailored Client to resolve the issue.

Tuesday, 19 July 2016

Login failed for user 'XXXX'. 4060,"42000",[Microsoft][SQL Server Native Client 10.0][SQL Server]Cannot open database XXXXXX requested by the login. The login failed.

The below error occurs when we try to convert the database from NAV2009 to NAV2013.


The following SQL Server error or errors occurred:

18456,"28000",[Microsoft][SQL Server Native Client 10.0][SQL Server]Login failed for user 'XXXXXX' 4060,"42000",[Microsoft][SQL Server Native Client 10.0][SQL Server]Cannot open database "XXXXXX'" requested by the login. The login failed.

Solution:

In this case ,please follow the below steps

1. We have to restore the NAV2009 backup again 
2. Open the database In NAV2009 and remove all tables which have property “LinkedObject“ Yes 


Note: Please also check the tables which are having LinkedObject=No.



It should be like below 




3. Try to convert the database in NAV20013.
4. Delete all temp windows logins\SID's

Now It will convert it in to NAV2013.

I hope this will help you.

Thanks!

Friday, 8 July 2016

How to Block Direct posting in NAV

Sometimes General Ledger (G/L) and sub ledgers (Customer,Vendor,Bank...) values won’t get tally, when users directly post transaction entries to these accounts using journals. 

To avoid these mistakes, Microsoft Dynamics NAV has a simple method to control this. This functionality called as Block for Direct Posting.

In order to block an account from direct posting, you need to go to particular G/L Account Card and uncheck  the "Direct Posting" check box. 

Once tick mark is removed, Microsoft Dynamics NAV will not allow any user to post journal entries directly to the particular G/L account. (At any given time you can put the tick mark back and allow to post directly).










Thursday, 2 June 2016

Error:TableData 2000000001 does not exist.

We get the below error when we try to connect the database



To resolve this error,we need to set the below permission in Sql server



I hope it will help you.

Friday, 19 June 2015

How to add nested sub pages in NAVISION

This is a basic concept of page  designing in NAV.
To add a sub page for another sub page follow below

Add the sub page and properties --> give Provider ID of another sub page,so that we can give the sub page of another sub page.

below example:

 


Tuesday, 17 February 2015

Error: Form Transformation

While transforming form to pages from NAV2009 or NAV2009R2 we may get the below error

Error: Schema: \ApplicationObjects.xsd
Error: Form -2: The validation for file:///C:/Users/xxx/Desktop/NAV2009/TransformationTool/ApplicationObjects.xsd.tmp.xml failed. Detailed Information: LineNumber=69, LinePosition=14
Error: Form -2: The element 'Properties' in namespace 'urn:schemas-microsoft-com:dynamics:NAV:ApplicationObjects' has invalid child element 'Style' in namespace 'urn:schemas-microsoft-com:dynamics:NAV:ApplicationObjects'. List of possible elements expected: 'IndentationColumnName, Editable, ShowAsTree, InstructionalTextML, Visible, Enabled, GroupType, IndentationControls, Description, Name' in namespace 'urn:schemas-microsoft-com:dynamics:NAV:ApplicationObjects'.

Error: Some input file can’t be validated by schema. Please, correct it and rerun tool again

Solution:Transformation tool won't support form control properties like FontBold,FontItalic. so we need to remove before form transformation.


Monday, 16 February 2015

How to Find Currently Running Queries in SQL Server

Some time Navision will take more time when execute an activity like data up gradation etc. We are not sure the particular activity is going on or not,in this case the following script find out which are the queries running currently on your server and the status of our activity.
SELECT sqltext.TEXT,req.session_id,req.status,req.command,req.cpu_time,req.total_elapsed_timeFROM sys.dm_exec_requests reqCROSS APPLY sys.dm_exec_sql_text(sql_handleAS sqltext
  
 the output will shown like below


Wednesday, 14 January 2015

How to send Documents as Email in NAV2015

 We have an option for sending attachments as email is available from Microsoft Dynamics NAV2015. 
We can see in sales invoices, sales credit memos, sales orders, sales quotes, reminders, and finance charge memos, as well as some posted documents. 

The option is available in the ribbon and called Email or Post and email depending on the context. 
It displays a dialog that lets you attach the document together with a short message and send this as email directly from Microsoft Dynamics NAV. 

In Microsoft Dynamics NAV Windows client you can decide to modify the email more in your default mail program. 
The default email sender address is based on the settings in the SMTP Mail Setup window. 
If SMTP is not configured or Outlook is not available, the .pdf file will open instead.

How to Stop Negative Inventory in NAV2013 R2

In earlier versions we have to customize NAV to achieve this but NAV2013R2 brings this feature as standard.


We can set up that outbound posting that brings inventory below zero is blocked. 
This can be set up per item or for all items. 

This setup is in the Inventory Setup, we can put a check mark in Prevent Negative Inventory field
 which specifies if you can post transactions that will bring inventory levels below zero.

The selection that you make in this field indicates the value in the Prevent Negative Inventory 
field on individual item cards. The values will either be Default (Yes) or Default (No)
which you can change.

I know have setup this for all Items i.e., in Inventory Setup and when I try to post an Item which has
 in sufficient Inventory then I got below error.

Microsoft Dynamics NAV
---------------------------
You have insufficient quantity of Item 1000 on inventory.
---------------------------
OK
---------------------------




One or more filters are not valid and will be ignored Message in NAVISION RTC

Today I tried to run (Preview) a Report with Date Filter and I got below confirmation message


Microsoft Dynamics NAV
---------------------------
One or more filters are not valid and will be ignored. Do you want to continue?
---------------------------
No   Yes
---------------------------




























Then I found that this is because of Wrong date format entered in Birth Date filter.
Date format in My system is set to DDMMYY and I entered as MMDDYY.

But this behavior is different in Classic Client (NAV2009R2).

I tried to enter same MMDDYY format in classic client Birth Date filed.

But It gives an error message as shown below
---------------------------
Microsoft Dynamics NAV Classic
---------------------------
'013150' is not a valid date.
---------------------------
OK 
---------------------------



Friday, 2 January 2015

How to restrict multiple logins for the same user ID

Some time we login multiple times with same user ID,but if we want to restrict this,please follow the below

In NAV 2013 and Later , Active Sessions (Table ID - 2000000110) gives 

 all the active session into the database.

For Restricting multiple Login we can use Codeunit 40 - LogInManagement.

So let's see how we can achieve this -

1. Design Codeunit 40, Navigate to Function CompanyOpen().

2. Append Below Lines as below -

the standard code looks like below
---------------------------------------------------
IF GUIALLOWED THEN
  LogInStart;
---------------------------------------------------

After
---------------------------------------------------
//Add code here BEGIN
ActiveSession.SETRANGE("User ID",USERID);
ActiveSession.SETRANGE("Client Type",ActiveSession."Client Type"::"Windows Client");
IF ActiveSession.COUNT > 1 THEN
  ERROR('You are Already Logined');
//Add code here END

IF GUIALLOWED THEN
  LogInStart;
---------------------------------------------------

The Client Type have following Options -
Windows Client,SharePoint Client,Web Service,Client Service,NAS,Background,Management Client,Web Client,Unknown

Above Code will Stop Windows Client to use multiple session with same User ID.

How it executes:

I will get the below error message while runnning RTC client second time which my first RTC client is already opened.



Tuesday, 30 December 2014

Error : Microsoft Dynamics NAV,The following SQL error was unexpected.

When we try to login with a user who does not have dbo-rights,we will get the following error

Error : Microsoft Dynamics NAV
---------------------------

The following SQL error was unexpected.
The SELECT permission was denied on the object 'User Property', database 'Cronus TEST', schema 'dbo'.

---------------------------
OK
---------------------------


Solution :


We can resolve the issue to run the following though sql management studio (replace tblYourTableName with your table name) 
grant select on dbo.tblYourTableName to public

How to Repeat Table Header on Each Page in NAV 2013 & NAV2013R2 Reports

After NAV2013 that the table header doesn't repeat when there is a next page.
Even the table properties Boolean Repeat Header Rows on New Page doesn't help.

So let's see how we can repeat header in New Page.

I will be doing it for NAV2013R2, and using Report Builder. The Steps Remain Same for NAV2013 also.
The following setting are required to repeat the header in New Page
1. Open the Layout of Report in

2. In the Column Group Pane Select Advanced Mode
3. Once in advanced mode you will see static Rows for Each Header Line

4. For Each Header Row that you want to repeat on New Page, select the corresponding Static Row and set these properties.


- Set KeepWithGroup to AFTER
- set RepeatOnNewPage to TRUE.


 When you click on a static Row, the corresponding row is selected in the table.

If you want to repeat all four lines in New Page, Repeat the steps for For all Header Rows.

Save the Report and Run in Role Tailored Client.

Monday, 29 December 2014

How to create a new ServiceTier in NAV2013R2

     1. Create a copy from the service-tier folder. (for example C:\Program Files\Microsoft Dynamics NAV\71\Service)

     2. Change the settings in file Customsettings.config. (database and instance name)
  
     3. Change in query below the values NewServiceTierName into the new name of the service-tier 
        Execute below query With PowerShell (Run As Administrator)

     4. New-Service -Name 'MicrosoftDynamicsNAVServer$NewServiceTierName' -BinaryPathName '"c:\Program Files\Microsoft Dynamics NAV\71\NewServiceTierName\Microsoft.Dynamics.Nav.Server.exe" $NewServiceTierName /config "c:\Program Files\Microsoft Dynamics NAV\71\NewServiceTierName\Microsoft.Dynamics.NAV.Server.exe.config"' -DependsOn 'NetTcpPortSharing' -Description 'Service handling NewServiceTierName' -DisplayName 'Microsoft Dynamics NAV 71 Server [NewServiceTierName]' -StartupType Automatic

     5 Execute with Command Prompt (Run as Administrator) the query: (change also NewServiceTierName)

      sc config MicrosoftDynamicsNavServer$NewServiceTierName depend= NetTcpPortSharing/HTTP

      6  Go to Services.msc and change the service-account from the new created service-tier into ….

      7  Start new service-tier.

Thursday, 25 December 2014

How to Debug RTC Pages in NAV2009

Debugging RTC Pages in NAV2009


   1.      Go to C:->Program Data-> Microsoft->Dynamics Nav->60->Server->Microsoft  Dynamics Nav Server->Source -> Codeunit. Here you can find the source of the pages DLL files written in C#, if the    pages are generated successfully.

   2.      Go to C:\Program Files (x86)\Microsoft Dynamics NAV\60\Service. Give full control to                      CustomSettings.config file.

   3.      Opne CustomSettings.config file. Make the enable debugging key to true by editing the following            settings for making the RTC page debugging possible :

 <add key="EnableDebugging" value="True"></add>

   4.      Run Visual Studio as Administrator.

    5.      Open the RTC page DLL file.

    6.      Go to Tools->Attach Process. Place check mark in Show Process from All Users check box.
    7.      Select the Nav Server process .

    8.      In the Page, put breakpoints wherever required.

    9.      Run RTC page in Nav. Then in Visual studio the code execution will be stopped at the break point.



               This way, you can make the RTC pages debugging possible.



                                                       ***Thank you very much***


Wednesday, 24 December 2014

Upgrade NAV5SP1 to NAV2013

Prerequisites:

The below database objects are required to go upgrade NAV5SP1 to NAV2013.

NAV5SP1 Base Database
NAV5SP1 customer Database
NAV2009R2 Base Database
NAV2013R2 Base Database

To Upgrade from NAV5Sp1 to NAV2009R2 Data Upgrade is not necessary, follow the steps below

·        Merge the customized objects
·        Open/Convert the database in Nav 2009 R2
·        Delete all the objects except tables
·        Cleanup the data which are not required. Like some add-ons might not require to upgrade,etc.
·        Import the latest merged Objects.
·        Transform Forms to page using Transformation Tool, if we find any matrix forms then we need to convert those matrix form to pages manually.
·        Customized Reports needs to be converted to RDLC
·        Compile the objects and resolve the compilation errors

1.   Update the Application Code.
Any customization in the customer’s old database must be implemented in the       new database
2.   Export all the objects in the new customized Microsoft Dynamics NAV 2013 database to an object file: objects.fob.
3.   Prepare for the data conversion.
a.   Make sure that you are the only user connected to the database.
b.   Back up the database and save the backup file in a safe place.
c.    Make a copy of the customer’s database in SQL Server Management Studio. You will upgrade the copy and keep the original.
d.   Verify that both your partner development license file and customer license file have been updated to Microsoft Dynamics NAV 2013.
e.   Identify a User ID and password for a superuser in the system or create a new superuser that you can use for the upgrade process. Log in as the superuser when you perform the upgrade.
f.     Verify that you have the dbcreator and securityadmin Server Roles for the Microsoft Dynamics NAV SQL Server instance, using SQL Server Management Studio. To manage companies, objects, and licenses within a Microsoft Dynamics NAV database you must also have the db_owner database permission.
g.   Disable integration properties for the database.
h.   Open the database in the Microsoft Dynamics NAV 2009 Classic with Microsoft SQL Server client.
i.     Run a database test to determine the state of the customer’s database.
Note: The database test can require a significant amount of time, depending on the size of the database.

4.   Import Upgrade Step 1 Objects
Import Upgrade601700.1.fob.

5.      Run the “Adjust Cost-Item Entries” batch job to ensure that the inventory cost data in the customer’s database is up to date.
6.   If your organization posts inventory costs to the Microsoft Dynamics NAV general ledger, run the “Post Inventory Cost to G/L” batch job.
Run the job for each company in the database.
7.      For the SCM feature, make the changes to tables 32, 83, 89, and 5841 described in the Update Guide.
8.   Perform Step 1 data conversion.
a.    In the Classic client, open Object Designer, and then open form 104001, Upgrade - Old Version.
  1. Choose Run.
  2. Choose Transfer Data.
Repeat the conversion for each company in the database.
9.   On form 104001, choose Delete Objects.
This runs codeunit 104002, Delete Old Objects, which deletes all of the objects that are not tables. It also deletes tables that belong to the features that are discontinued in Microsoft Dynamics NAV 2013.
10.Create the New Microsoft Dynamics NAV Database.
This involves installing Microsoft Dynamics NAV 2013, and then opening your database in the Microsoft Dynamics NAV 2013 development environment.
See the Upgrade Guide for details.
11.Change the compatibility level of the database.
For SQL Server 2008 and SQL Server 2008 R2 editions, verify that the compatibility level of the database is set to 100. For SQL Server 2012, the appropriate compatibility level is 110. To set the compatibility level, run a query like the following in Microsoft SQL Server Management Studio:

USE [master]; ALTER DATABASE [YourDatabaseName] SET COMPATIBILITY_LEVEL = 100
12.   Import all customized Microsoft Dynamics NAV 2013 objects.
13.   Compile all objects.
14.Import Upgrade Step 2 objects.
 Import Upgrade601700.2.fob in the development environment.
15.Set the language
In the development environment, choose Tools, choose Language, and then select the language of the old customer database.
16.Perform Step 2 data conversion.
  1. Open page 104002, Upgrade - New Version.
  2. Choose Run.
    This opens the Windows client and displays page 104002, Upgrade - New Version.
Choose Transfer Data.
This runs codeunit 104048, Upgrade NAV 2009 Step 2.
17.Update source codes.
Run page 257, Source Codes, in the Windows client. Note any source codes that have been added, and then update the Source Code and Source Code Setup tables for any additional source codes in the new version.
18.Initialize all companies.
For each company, run codeunit 2, Company-Initialize and open page 531, Setup Checklist.
19.Update data in tables that are not specific to a single company.
This includes tables 2000000003 (Member Of), 2000000004 (User Role), 2000000005 (Permission), 2000000053 (Windows Access Control), and 2000000203 (Database Key Groups).
20.   Upgrade Roles (Permission Sets) and Permissions.
21.Delete obsolete tables
a.    Open Object Designer
b.    Open form 104002.
c.    Run Upgrade - New Version.
d.    Choose Delete, and then choose Mark Unused Old Tables.
e.      Set a filter on the Version List column to select tables marked as “Old Unused Table - marked for deletion.
f.       The Edit menu, choose Delete to delete the tables.
22.Delete Upgrade Toolkit Objects
  1. In form 104002, choose Delete, and then choose Mark/Delete Upgrade Toolkit.
  2. All Upgrade Toolkit objects, except tables, are removed automatically. The tables are marked for deletion.
  3. Set a filter on the Version List column to select tables marked as “Upgrade Toolkit Tables - marked for deletion.”
On the Edit menu, choose Delete to delete the tables.
23.Test the database
a.    Test everything except field relationships between tables. If the test fails, follow the workflow for repairing damaged databases.
b.    Run the remaining part of the database test, which is to test field relationships between tables.
Test the upgraded item ledger entry invoiced quantities to make sure that any date compressed item ledger entries have been upgraded correctly.

                                                     
                                          ***Thank you very much ***