ABOUT
Rue de Net specia- lizes in professional, personal and honest consultancy in relations to Microsoft Dynamics NAV and comple- mentary technology and software like .NET, web services, web shops, integration tools, web applications, executive information panels and other user interfaces.

NET·Conductor NAS Guide

The following are crude installation guidelines for the NET·Conductor running in NAS.

Why use NAS?

When running the NET·Conductor in a Dynamics NAV client it will stop running upon every ERROR or CONFIRM that is being made by code that is run through the NET·Conductor.

To prevent this you should run the NET·Conductor in a NAS. In this case all the ERROR, CONFIRM, TESTFIELD, DIALOG and other GUI usage will produce an error that is sent back to the client, stored in the Windows Event Viewer and possibly sent via e-mail to the administrators of the NET·Conductor.

However, before the NAS, including the NET·Conductor can be started you need to follow these instructions.

1) Update NASHandler

Update the NASHandler function in CodeUnit 1 ApplicationManagement so that it supports the 'NETC' parameter.

Please not that the following code changes are suggestions and you may not want to make the changes exactly as shown here. Also, ensure you understand the code changes you are about to make. Do not follow these change suggestions blindly.

In 3.60, 3.70 and 4.00 early in the function there is code similar to this:

...
REPEAT
   SepPosition := STRPOS(ParamStr,',');
   IF SepPosition > 0 THEN
      Parameter := COPYSTR(ParamStr,1,SepPosition - 1)
    ELSE
      Parameter := COPYSTR(ParamStr,1);
...

In 3.60 the next statement is a CASE statement but in 3.70 and 4.00 it is an IF. Regardless of the statement we suggest that you add code after the above snippet and before the next statement (being a CASE or an IF), as shown here:

...
REPEAT
   SepPosition := STRPOS(ParamStr,',');
   IF SepPosition > 0 THEN
      Parameter := COPYSTR(ParamStr,1,SepPosition - 1)
    ELSE
      Parameter := COPYSTR(ParamStr,1);

	//NETConductor: Begin
	IF COPYSTR(Parameter,1,5)='NETC:' THEN BEGIN
	   NETConductor.Start(COPYSTR(Parameter,6));
	   EXIT;
	END;
	//NETConductor: End
...

NB: The suggested code change does not support any parameters, in the NAS comma-separated startup parameter, after the 'NETC' parameter. If you need that, you may want to create your own flavor of these changes, as mentioned earlier.

Then, before you can compile and save the CodeUnit you have to create a Local variable called 'NETConductor' of the type 'CodeUnit 84920 NETConductor' and you are done!

2) Create NET·Conductor Setup

Create your NET·Conductor Setup ID (i.e. NC0001). We suggest that you use a Dynamics NAV Client (and form 84920) to create the setup ID and test that it will actually start.

Before you continue ensure the user has the necessery Dynamics NAV Permissions

3) Start Dynamics NAV Application Server

Then you can start the Dynamics NAV Application Server, which we suggest you do using the Application Server Manager. Sample parameters would be:

Database Server Name     : CRONUS
Database                 : Dynamics NAV Demo Database
Company Name             : CRONUS UK Ltd.
Start-Up Parameter Value : NETC:NC0001
Net Type                 : TCP/IP
Object Cache Size        : 0

Ensure the user has the necessery Dynamics NAV Permissions

...and then you press the 'Start Service' button.

NB: When NAS is started you will be able to find all messages regarding it's startup and shutdown in the Windows Application Log, using the Windows Event Viewer (%SystemRoot%\system32\eventvwr.msc).