Get a list of Pervasive / Actian PSQL databases using C# and DTO

Recently a question came up on how to get a list of all of the database names on a Pervasive / Actian PSQL server from C#. The short answer is to use the DtoDatabase object within the Distributed Tuning Object (DTO) COM object. A reference to the DTO Library will need to be added for this code to work.
This sample is a simple console application that takes three paramaters (ServerName, UserName, Password).
Here’s the code sample that shows how to get the list:

using System;
using DTOLib;

namespace dtoTest
	class Class1
		static void Main(string[] args)
			string compName = null;
			string userName = null;
			string password = null;
			DTOLib.dtoResult result;
			if (args.LongLength < 1)
				Console.WriteLine("Invalid options.\n");
			if (args.LongLength == 3)
				compName = args[0].ToString();
				userName = args[1].ToString();
				password = args[2].ToString();
			Console.WriteLine("List Pervasive Database using DTO and C#");
			DtoSession mDtoSession = new DTOLib.DtoSession();
				result = mDtoSession.Connect(compName, userName, password);
				if (result != 0)
					Console.WriteLine("Error connecting to server.  Error code:");
					Console.WriteLine("Connected to " + mDtoSession.ServerName);
					DtoDatabase mDtoDatabase = new DTOLib.DtoDatabaseClass();
					int dbnCount = mDtoSession.DSNs.Count;
					Console.WriteLine("Found " + dbnCount.ToString() + " DBNs");
					for (int iCount = 1; iCount <= dbnCount; iCount++)
						Console.WriteLine("DBN " + iCount.ToString() + ": ");
						mDtoDatabase = mDtoSession.Databases[iCount];
						Console.WriteLine("Name: " + mDtoDatabase.Name);
						Console.WriteLine("DDF Path: " + mDtoDatabase.DdfPath.ToString());
						Console.WriteLine("Data Path: " + mDtoDatabase.DataPath.ToString());
						Console.WriteLine("Flags: " + mDtoDatabase.Flags.ToString());

					result = mDtoSession.Disconnect();
			catch (Exception e1)

IsCmdBld.exe causes -1073741819 error

Recently while trying to build an InstallShield 2012 InstallScript installation, the Jenkins job failed because IsCmdBld.exe returned an errorlevel of
-1073741819. After searching through various forums and web sites, I found a workaround that involved disabling the .NET dependency scanning. This was done by setting the “.NET Scan at Build” option on the component to “None”. This let the build complete with no errors displayed.
Eventually I also found one post related to an error with the InstallShield dependency scanner. This error was later found to be a known issue in InstallShield 2012. It had been fixed in InstallShield 2013 and InstallShield 2015. The forum post included a link to a Knowledge Base article ( that includes a hot fix for InstallShield 2012.

WebAPI routes returning 404 error.

Recently, I was working on a WebAPI project and had it working in Visual Studio 2013 using IIS Express.  Then I deployed it to a standard IIS running on Windows 7 and everything failed.   Status 404 was being returned from all routes.  I tried all of the standard troubleshooting options but finally found the problem.

My Application Pool was set to .NET 2.0.  I reset it to .NET 4.0 and everything started working just fine.