Saturday, December 10, 2016

How to solve C/Side hyperlink failed in MS Dynamics NAV 2017?

Are you also Getting the Same Error ?



This error only occurs when we have all the above or more than 1 vesions installed in our system and we have uninstalled any higher version of NAV.

Cause: -

DUE TO uninstall , System Registry might have got some error or deleted.

Solution : -

You have uninstall all the versions and then reinstall each version in ascending order, once all versions are installed , please don't uninstall any upper version. I hope this post will surely help all other NAV Developers and subscribe via email so our new post will reach you directly.

You can also use NAV Protocol Handler. To download NAV Protocol Handler Click Here.

Friday, December 9, 2016

What is System Indicator in NAV 2017 ?


System Indicator in NAV

Defination :

System Indicator is a Field in NAV Company Information Table 79 which can be used for showing any Text in RTC Client as Shown in below screenshot.








I hope you can use it for indication on your Test or Live RTC to remember on which client you are working.

How to add a field in Purchase Header and flow it in G/L Entry in NAV 2017?


To Flow a Field in NAV 2017 Purchase Header - > GL Entry


Flow is From

Purchase Header ---------------> Gen. Jnl. Line ------------------> GL Entry

In the below Eg. I had added a Narration Field on Header and Flow in To GL Entry.


Step 1. Add your Field on Purchase header , G/L ENTRY and Gen. Journal Lines table. as shown in figure also please Check all the fields added must have a same Id.













Step 2. Add your code to Gen Journal Table 81 inside Function CopyFromPurchaseHeader.






Step 3. Add your code to G/L Entry table 17 inside Function CopyFromGnlJnlLine.
Step 4.Add your Code to Codeunit 90 inside Function InsertICGnlJnlLine



Post your Purchase Order.

Your Result is shown below :-


Please Note :- This Field is Valid in NAV 2017 only due to function changes although the method is same in previous version also.

I had used Demo DB so Please be aware about your Database. I hope this will be fruitful for all my juniors in Nav. Keep in touch and subscribe via Email below so our team will intimate you once we get our next Post.

You can also Download these objects From Here :- Click Here

Wednesday, December 7, 2016

How to implement images in MS Dynamics NAV 2017?


Image for Customers and Vendors

With NAV 2017 , you can have your Customer and Vendor imges attached on thier card also you can see in NAV Web Client how attractive the feature is implemented.

To implement the same NAV has created 2 new tables Customer Picture and Vendor Picture with the use of Addin in NAV. To implement the same you to check the actions and define the pagelink as defined in NAV Demo.

So Let's Enjoy the meal. And have nice development ahead with your partners.



How to use SETTABLEVIEW Function in Navision?

SETTABLEVIEW

This is a very important function that can be used in various scenarios ccording to business requirement and dealing.

Defination :-

This function applies filters to the record for the Pages , Report or Xmlport.

Syntax :-    SETTABLEVIEW(Record)

To see more about this please Click Here.

Implementation :-

To use this function we have to create 2 variables and I am adding this function on my customer card to see the impact. 







Tuesday, December 6, 2016

Whats new in G/L Accounts of NAV 2017?

 NAV 2017 

We can adjust our chart of accounts according to differents Categories in Navision. And these categories may be further divede into another different Categories.


2 other new tabs are also defined for Consolidation and Cost Accounting , these new tabs are basically defined to consolidate te Debit and Credit account of this particular GL Account.


In The Page also we have new functionality as follows.



To get most updated news about navision kindly visit this blog regularly and subscribe by Email below so we can reach you everyday.


What is Sales Price and Purchase Price in Navision?

Sales Price & Purchase Price 

These are the price which we can define for a particular item. It can be used and categorised on different basis. We can also define prices for different Dates in a month.



How to define it :- 

We can use these prices in normal indian business scenarios where we want to give some discounts to specific Customers and Vendors as per the requirement.

To define the special prices GOTO Item and search for special prices at home and navigate ribbon.

Advantage:-

In the Sales Price we can define the Direct unit cost of items according to specific customers.

We can also create different customers and accordingly we can define the Sales Price for the items.

We Can also define Price for all Customers. 

The same can be used for Vendors but here we can only define to buy from a particular vendor.

Error while defining Sales & Purchase Price :-

Now , after defining the prices in Sales Price and Purchase Price the issue arises why the sales price is defined correctly instead the system picks up the Last Direct according to the Method defined for stock. For fast solution please check these points.

1. Quantity Field must be blank for accurate transaction of Direct Unit cost in Purchase/Sales Line.

2. Currency Field must be blank or same as in sales/purchase lines.

Starting Date and Ending Date must have a value.


Please comment if still the prices are not picking correctly. or for any other customization.


Friday, December 2, 2016

How to use Temporary Tables in Navision?

What are Temporary Tables in Navision?


Temporary Tables are basically a Temporary variable which points to table and are in use until the table is not closed from Client. This image will define it much better.

For more reference , Please click here on MSDN.

Now see the use of Temporary Tables in this code.


Result :



Thursday, December 1, 2016

What is the difference between CLEAR & RESET Functions in NAV?


What is the use of RESET & CLEAR : -

Basically when we use a want to reuse a variable we need to unapply all the filters that are previously applied on that variable, this is why we need to CLEAR or REST that variable.

If its string type we use ABC=''; IF its Integer type we use ABC=0;
OR we use CLEAR(ABC);
Now, when we are using a RECORD type variable we always use


CLEAR(ABC) or ABC.RESET;

Difference is that while using RESET it clears all the filters already applied on that variable and if any key is changed it will reset the primary also.


CLEAR is 1 more step Ahead that it will Clear all the fields individually from this recor type variable.

For reference please check :-After RESET


After Clear



Wednesday, November 30, 2016

How to use MARK and MARKED only function in MS Dynamics NAV 2017?

These 2 functions are similar to NAV Developer as we do use for Objects using CTRL +F1.


HERE is an example in which I had used to mark some records of Customer table with Starting Alphabet as "C" and with Location Code as "BLUE".


So Lets see the screenshot for reference :-



The Result is :-


Monday, November 21, 2016

How to INSERT a Record in Customer table and then modify that record?


Use OF AL to update insert delete in MS Dynamics NAV 2017?


We can insert a record and modify that inserted record into table using Codeunit.

For an Example: I am updating my name in Customer table and updating that Name.

Look at this Code.






After Running the Code-unit we got this desired result:-





Saturday, November 19, 2016

Bug Fix Needed on webSite of MSDN for query Function SAVEASCSV?


There is a function explained on MSDN website on this link SAVEASCSV for Query Object.


Syntax of Function :

QueryVariable.SAVEASCSV (FileName[, Format][, FormatArgument])
File Name is a text path where query will be Saved.
Format is a option field with 0/1 as parameters
0 means to provide length maually in FormatArgument between any 2 columns
1 means to provide in FormatArgument as , ; or 'tab' for space.

Bug No. 1


'tab' is not working with 1 as paramater it just copies the word tab in between coluum.
Bug No. 2
Microsoft has not written any example with 'tab'
Bug No. 3
Microsoft should notice that 'tab' is working with 0 and not with 1 as FORMAT parameter.
ScreenShot is attached below :-









Friday, November 18, 2016

Why are 2 Allow Posting Dates in G/L Setup and User Setup are present in MS Dynamics NAV ?


Two Different allow posting dates in General Ledger Setup and User Setup?







Yes one is for common users and one is for particular users.
Here the defined dates will be checked once a posting routine action is done in Navision.

But what is the priority base? Which will be selected if both are defined.

Priority will be given to User Setup first then G/L Setup.
For E.g.
In G/L Setup Dates are : 01012016..01022016
In User Setup Dates are : 01122015..31122015 for user XYZ.

Then while posting first user setup will be checked. That means if user XYZ is posting on date 29122015. Then will be able to post. Hope you understand the concept.

Wednesday, November 16, 2016

NAV 2017 GL SETUP of MS Dynamics NAV :- General Fast Tab Explained


NAV 2017 General Ledger Setup 



NAV 2017 GL SETUP General TAB

NAV 2017 has already been launched with new functionalities both for developers and Client.
Few important fields for developers in General Tab are as follows:-

1. LCY CODE and its SYMBOL Field.
2. Allow Posting Date.
3. BILL TO Sell TO VAT Calc.
4. Invoice Rounding Precision and its method.
5. Use Legacy G/L Entry Locking.

All Setups are placed at one place as in Screen 1 above. We should follow the same in below versions.







Monday, November 14, 2016

HOw USE OF FINDSET in MS Dynamics NAV 2017?.

How to use FINDSET



As per MSDN,Findset gets the records on the basis of filters applied over the record type.
If now filters are applied then we can use it to update all records present in table using REPEAT UNTIL.

I had defined these two variables in navision.

DIFFERENCE between FINDSET,FINDFIRST,FINDLAST in NAVISION.

FINDSET :- It retrieves 50 records in tables and update it one by one.
FINDLAST :- It points to LAST Record in a DATASET Filter.
FINDFIRST :- It points to FIRST Record in DATASET FILTER.



Following is the code which I had written to get the processed data in a table.




This is the desired result:













How to use DATE2DWY Function in Navision?.


CASE are similar to all other languages in Navision. 


The only difference is in Syntax but the basic concept remains same.


Here I am going to convert a Date to a number using DATE2DWY and that number is used in CASES to define a Weekday in Navision. 

So these variables I had defined:





The Code is very simple just notice the syntax for CASE in Navision.







Here is the result.




Difference B/W Pass By Reference & Pass By Value (Miracle Solved & Explained For all Languages)

Functions are created in all languages and perform various tasks uniquely. 

That's the reason why functions are useful in a coding of all types Languages.

Creating a Function needs to be needs needs 3 Basic Steps :


1. Defining and Creating the Defination of Function.

2.Calling the Function.

3. Passing the Paraments and Arguments into the function so that it provide output.

Now, 
as navision is using C/AL Language in its heart to define and work the logics.There is only one thing common is Function.

Calling the Function and creating the Function and Defining the Function.


Due to this Fact , understanding Functions is very much necessary for beginners and experts of NAV TECHNICAL Consultants.

Functions are easy to create in NAV. Now passing the parameters and calling the functions is explained below.

There are two functions which I had created and Called it via 

CALL BY REFERENCE & CALL BY VALUE.





By Default All Variables in Functions inside NAV Dev are Pass by Value which means a copy is created for parameter and passed.

Variables Used:
CustRec     Record    18
Old Name   Text 50
New Name  Text 50
ChangeCustomerName and ChangeCustomerNameRef are two functions Created in which
Customer variable is taken First one is Pass By Value and Second one is Pass By Reference.


The Code is As Follows :


(This code is only for study purpose taken as Example.If any Objections then Kindly mail)



The Final Result is as under screenshot.

Result 1:-


Result 2:




Tuesday, September 27, 2016

How to separate comma separated value in NAV and import the values in table MS Dynamics Navision?

Comma , Separated Value Retrieval

Now a days, we are moving to more around e commerce industry which works in 24*7 format so to ease the performance and manual work we prefer to use web services. These web services include a set of format which includes some logical values. So in this blog we will try to extract some values from a returned web services.

What we are going to use?

There is a function in NAV called SELECTSTR .

Acc. to msdn,
SELECTSTR treats string values as OPTIONS. This means that identical values in different strings are not allowed.
Any trailing commas are removed before the operation begins.
If Number is less than 1 or greater than the number of real values (excluding trailing commas) in the string, then an error is returned.
Quotes are not supported. For example, a,b,"c,d",e is treated as a five-element substring where substring 4 is d".

Example:-

We are going to retrieve 

1.Account Type
2.Url
3.ID
4.Name
from this returned value from web service.

{"type":"Account","url":"/services/data/v32.0/sobjects/Account/001N000000pEFqVIAW"},"Id":"001N000000pEFqVIAW","Name":"aafag"} 

How to implement the customization and store it in the Table.

Declare variables as per need and requirement.

This is the code which I had written for select the string and then simply insert it into our table.



The final result is here.



You can download the objects by: