Skip to main content

Notifications

Microsoft Dynamics NAV (Archived)

Error while doing programming using extensions

Posted on by 2,576

Hi,

While creating '.navx package' during programming using extensions I get the following error

This is the command that I used:

PS C:\Users\cfadmin> New-NAVAppPackage -Manifest (Get-NAVAppManifest -Path C:\Backup_Tina\Extensions\Manifest file\Location.xml) -Path "C:\Backup_Tina\Extensions\NAVx package\MyLocation.navx" -SourcePath "C:\Backup_Tina\Extensions\Delta objects\"

The following is the error:

Get-NAVAppManifest : A positional parameter cannot be found that accepts argument 'file\Location.xml'.

At line:1 char:30

+ New-NAVAppPackage -Manifest (Get-NAVAppManifest -Path C:\Backup_Tina\Extensions\ ...

+                              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidArgument: (:) [Get-NAVAppManifest], ParameterBindingException

    + FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.Dynamics.Nav.Apps.Tools.GetNavAppManifest 

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Error while doing programming using extensions

    Thank you very much Mohana. Very easy fix for you but really difficult for me. I'm surprised by case sensitive rule and I overloked "NAV". I was focused to different topics, no idea about function names. Thank you once again. Issue is solved.

  • Verified answer
    Mohana Yadav Profile Picture
    Mohana Yadav 59,135 Super User 2024 Season 2 on at
    RE: Error while doing programming using extensions

    function names are case sensitive

    OnNavAppUpgradePerDatabase

    and

    OnNavAppUpgradePerCompany

    you have used capital NAV

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Error while doing programming using extensions

    Hello,

    I have read all posts, I have created codeunit and 2 functions but I still get the error like was already mentioned. 

    The script and the error:

    PS C:\WINDOWS\system32> Get-NAVAppManifest -Path 'C:\Temp\Exten\VitMal.xml' | New-NAVAppPackage -Path 'C:\Temp\Exten\VitMal_Exten.navx' -SourcePath 'C:\Temp\Exten\DELTA.txt' -Force -Verbose
    VERBOSE: Performing the operation "New-NAVAppPackage" on target "Writing package file at C:\Temp\Exten\VitMal_Exten.navx".
    New-NAVAppPackage : The package contains changes to the database schema that are not handled in upgrade code.
    At line:1 char:55
    + ... tMal.xml' | New-NAVAppPackage -Path 'C:\Temp\Exten\VitMal_Exten.navx' ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidArgument: (Microsoft.Dynam...ewNavAppPackage:NewNavAppPackage) [New-NAVAppPackage], InvalidOperationException
    + FullyQualifiedErrorId : Microsoft.Dynamics.Nav.Apps.Tools.NewNavAppPackage

    The attached picture contains more information. I will appreciate any suggestion. 

    Extension_2D00_Issue.png

  • Tina Menezes Profile Picture
    Tina Menezes 2,576 on at
    RE: Error while doing programming using extensions

    Hi all,

    Yes, I face the same problem.

    How much time does the app takes to publish?

    Its been almost 24 hours yet my extension app isn't published ?

    What is the solution to this?

  • CDsilva Profile Picture
    CDsilva 4,184 on at
    RE: Error while doing programming using extensions

    Hi

    It takes much time to publish the Extensions. even though waiting for 4 to 5 hours its displays running script.

    Can someone tell me a solution to it.

    Thank you.

    -Chris

  • Tina Menezes Profile Picture
    Tina Menezes 2,576 on at
    RE: Error while doing programming using extensions

    Hi all,

    Thanks a lot. Your suggestions worked.

  • RE: Error while doing programming using extensions

    Thank you Mohana your suggestion worked.

  • Verified answer
    Mohana Yadav Profile Picture
    Mohana Yadav 59,135 Super User 2024 Season 2 on at
    RE: Error while doing programming using extensions

    Try

    cmdlet :Publish-NAVApp -Path C:\Extensions\navxPackage\MyLocationExt.navx -ServerInstance DynamicsNAV100 –SkipVerification

  • RE: Error while doing programming using extensions

    Hi all,

    Thanks to the above suggestions I was able to successfully create the .navx file but on further publishing the .navx file I am facing the following error on using the

    cmdlet :Publish-NAVApp -Path C:\Extensions\navxPackage\MyLocationExt.navx -ServerInstance DynamicsNAV100 

     

    Error Message:

    Publish-NAVApp : You cannot publish an extension that has not been code signed. To overrule this check and publish the unsigned  extension, set the –SkipVerification parameter.

    At line:1 char:1


    Please suggest a solution to the above error. Thanks in advance.

  • Verified answer
    Saurav.Dhyani Profile Picture
    Saurav.Dhyani 17,965 Super User 2024 Season 2 on at
    RE: Error while doing programming using extensions

    Hi Tina,

    Everything is already said by Yukon .

    1. Change the Codeunit Type to Normal instead, upgrade.

    2. If you are testing how extension work then you don't need to put code under these function, but if you are actually developing a re-sellable extension then follow the article suggested . 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans