{"id":43484,"date":"2017-02-10T10:00:09","date_gmt":"2017-02-10T08:00:09","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/nav\/?p=14115"},"modified":"2023-05-31T15:24:50","modified_gmt":"2023-05-31T22:24:50","slug":"coffee-break-navdiag","status":"publish","type":"post","link":"https:\/\/www.microsoft.com\/en-us\/dynamics-365\/blog\/it-professional\/2017\/02\/10\/coffee-break-navdiag\/","title":{"rendered":"Coffee Break: NAVDiag"},"content":{"rendered":"
In the previous two posts, Automation Part 1 <\/a>and Part 2<\/a>, we talked about how to easily bring PowerShell into Dynamics NAV.<\/p>\n Based on the applicability and interest shown so far we wanted to continue on the\u00a0previous thread and address some of the suggestions we received, as well as add some functionality. We called the result NAVDiag<\/strong>. You can use this as a tool that helps you simplify and speed up the troubleshooting. But above all: We hope this will\u00a0create engagement around tooling\u00a0possibilities and inspire for more suggestions.<\/p>\n In this edition, we have added examples of how to read the license file <\/em>and read the config file<\/em>.\u00a0Exporting license file\u00a0is done using a NAV cmdlet, and because running NAV cmdlets requires elevated permissions, \u00a0in order to run NAV cmdlets from this tool your NAV Server account must be an admin account. In general, we are trying to avoid functionalities that require elevated permissions in these examples, as the\u00a0point is simplicity and\u00a0the ability to use this on a default configuration without any further installation or modifications needed. But after your feedback we thought\u00a0this\u00a0could be\u00a0useful to have under a caution that running actions that invoke NAV cmdlets will fail unless the NAV Server user account has elevated permissions.<\/p>\n Another functionality we added\u00a0is capturing repro steps when troubleshooting using Windows Steps Recorder. This is initiated using client side .NET interoperability, so this functionality will not run (nor be present) on a Web client (see limitations<\/a>). The same would\u00a0apply to\u00a0collecting diagnostic details client side (can be used on Windows client only).\u00a0\u00a0Collecting client-side data was one of the questions\/suggestions we got and is something that\u00a0we will come back to soon. For now, we would like to wrap up the functionalities that do not require any changes to default configuration.<\/p>\n So here it is:<\/p>\n The tool now allows you to collect diagnostics, the same diagnostics we presented in the last post, with added examples of reading the config file, the license file and Steps Recorder.<\/p>\n Record Steps<\/em> action will allow user to record\u00a0problem steps and save the output. This is basically just a call\u00a0to the built-in Windows Steps Recorder function, but still\u00a0useful to have as a part of the tool. Finally, the License File <\/em>action will\u00a0read the license file, the specified NAV Server account has elevated permissions.<\/p>\n There will be more coming up but if you find this useful and have further ideas about how this can\u00a0be improved and used in your daily tasks, please let us know.<\/p>\n<\/a><\/p>\n