List models (Windows PowerShell) :-
1.To list the models in a layer, at the Windows PowerShell command prompt, PS C:\>, type the following command, and then press ENTER.
Get-AXModel -Layer <LayerName>
2.To list the models in the model store, at the Windows PowerShell command prompt, PS C:\>, type the following command, and then press ENTER.
Get-AXModel
4.To list the models in the model store, at the command prompt, type the following command, and then press ENTER.
axutil list
src :-https://technet.microsoft.com/EN-US/library/hh433542.aspx
-------------------------------------------------------------------------------------------
1.To list the models in a layer, at the Windows PowerShell command prompt, PS C:\>, type the following command, and then press ENTER.
Get-AXModel -Layer <LayerName>
2.To list the models in the model store, at the Windows PowerShell command prompt, PS C:\>, type the following command, and then press ENTER.
Get-AXModel
List models (AXUtil) :-
- On the Start menu, click Command prompt.
- Navigate to the directory for the management utilities. Typically, the location of this directory is %ProgramFiles%\Microsoft Dynamics AX\60\ManagementUtilities.
- To list the models in a layer, at the command prompt, type the following command, and then press ENTER.
axutil list /layer :<layername>
axutil list
src :-https://technet.microsoft.com/EN-US/library/hh433542.aspx
-------------------------------------------------------------------------------------------
AxUtil and Windows PowerShell Commands for
Deploying Models in AX 2012
Two command line tools are available for deploying and managing models and the model store:
- Windows PowerShell, a command-line scripting tool
- AXUtil, a command-line utility
Access Windows PowerShell
- On the Start menu, point to All Programs, point to Administrative Tools, and then click Microsoft Dynamics AX Management Shell.
- At the Windows PowerShell command prompt, PS C:\>, enter the Get-Help command, and then press ENTER.
Get-Help AXModel (The command in this example returns a list of all model-related cmdlets.)
Get-Help Export-AXModel -Full (The code in this example retrieves help for the Export-AXModel cmdlet.)
Export an .axmodel file (Windows PowerShell)
- On the Start menu, point to All Programs, point to Administrative Tools, and then click Microsoft Dynamics AX Management Shell.
- At the Windows PowerShell command prompt, PS C:\>, type the following command, and then press ENTER.
Export-AXModel –Model <name> -File <Filename.axmodel>
This example exports the specified model to a file that has the specified file name.
You can use the –Server, –Config, or –Database parameters to specify the environment to export from.
Import an .axmodel file (Windows PowerShell)
- On the Start menu, point to All Programs, point to Administrative Tools, and then click Microsoft Dynamics AX Management Shell.
- At the Windows PowerShell command prompt, PS C:\>, type the following command, and then press ENTER.
Install-AXModel -File <Filename.axmodel> -Details
This command installs the specified file in the same layer that it was exported from.
You can use the –Server, –Config, or –Database parameters to specify the environment to import to.
AxUtil
After you install Microsoft Dynamics AX, the applicable AXUtil commands are available from the directory for Microsoft Dynamics AX Management Utilities.
To view the Help for AXUtil, enter the command AXUtil /?.
Access AXUtil
- On the Start menu, click Command prompt.
- Navigate to the directory for the management utilities. Typically, the location of this directory is %ProgramFiles%\Microsoft Dynamics AX\60\ManagementUtilities.
- At the command prompt, type the following command, and then press ENTER.
axutil /? (This command displays the Help for AXUtil.)
Export an .axmodel file (AXUtil)
- On the Start menu, click Command prompt.
- Navigate to the directory for the management utilities. Typically, the location of this directory is %ProgramFiles%\Microsoft Dynamics AX\60\ManagementUtilities.
- At the command prompt, type the following command, and then press ENTER.
axutil export /model:<modelname> /file:<filename> /verbose
This example exports the specified model to a file that has the specified file name.
Import an .axmodel file (AXUtil)
- On the Start menu, click Command prompt.
- Navigate to the directory for the management utilities. Typically, the location of this directory is %ProgramFiles%\Microsoft Dynamics AX\60\ManagementUtilities.
- At the command prompt, type the following command, and then press ENTER.
axutil import /file:<filename> /verbose
This command installs the specified file in the same layer that it was exported from.
If the installation fails because of a conflict, we recommend that you rerun the command, and use the /conflict:push option to push the element that has the conflict to the related update layer. You can then resolve the conflict. For more information, see How to: Resolve Conflicts After Importing a Model.
src:- https://technet.microsoft.com/EN-US/library/hh352314.aspx
src:- https://technet.microsoft.com/EN-US/library/hh456294.aspx